1// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. 2 3package networkmanager 4 5import ( 6 "fmt" 7 "time" 8 9 "github.com/aws/aws-sdk-go/aws" 10 "github.com/aws/aws-sdk-go/aws/awsutil" 11 "github.com/aws/aws-sdk-go/aws/request" 12 "github.com/aws/aws-sdk-go/private/protocol" 13 "github.com/aws/aws-sdk-go/private/protocol/restjson" 14) 15 16const opAssociateCustomerGateway = "AssociateCustomerGateway" 17 18// AssociateCustomerGatewayRequest generates a "aws/request.Request" representing the 19// client's request for the AssociateCustomerGateway operation. The "output" return 20// value will be populated with the request's response once the request completes 21// successfully. 22// 23// Use "Send" method on the returned Request to send the API call to the service. 24// the "output" return value is not valid until after Send returns without error. 25// 26// See AssociateCustomerGateway for more information on using the AssociateCustomerGateway 27// API call, and error handling. 28// 29// This method is useful when you want to inject custom logic or configuration 30// into the SDK's request lifecycle. Such as custom headers, or retry logic. 31// 32// 33// // Example sending a request using the AssociateCustomerGatewayRequest method. 34// req, resp := client.AssociateCustomerGatewayRequest(params) 35// 36// err := req.Send() 37// if err == nil { // resp is now filled 38// fmt.Println(resp) 39// } 40// 41// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/AssociateCustomerGateway 42func (c *NetworkManager) AssociateCustomerGatewayRequest(input *AssociateCustomerGatewayInput) (req *request.Request, output *AssociateCustomerGatewayOutput) { 43 op := &request.Operation{ 44 Name: opAssociateCustomerGateway, 45 HTTPMethod: "POST", 46 HTTPPath: "/global-networks/{globalNetworkId}/customer-gateway-associations", 47 } 48 49 if input == nil { 50 input = &AssociateCustomerGatewayInput{} 51 } 52 53 output = &AssociateCustomerGatewayOutput{} 54 req = c.newRequest(op, input, output) 55 return 56} 57 58// AssociateCustomerGateway API operation for AWS Network Manager. 59// 60// Associates a customer gateway with a device and optionally, with a link. 61// If you specify a link, it must be associated with the specified device. 62// 63// You can only associate customer gateways that are connected to a VPN attachment 64// on a transit gateway. The transit gateway must be registered in your global 65// network. When you register a transit gateway, customer gateways that are 66// connected to the transit gateway are automatically included in the global 67// network. To list customer gateways that are connected to a transit gateway, 68// use the DescribeVpnConnections (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeVpnConnections.html) 69// EC2 API and filter by transit-gateway-id. 70// 71// You cannot associate a customer gateway with more than one device and link. 72// 73// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 74// with awserr.Error's Code and Message methods to get detailed information about 75// the error. 76// 77// See the AWS API reference guide for AWS Network Manager's 78// API operation AssociateCustomerGateway for usage and error information. 79// 80// Returned Error Types: 81// * ValidationException 82// The input fails to satisfy the constraints. 83// 84// * ServiceQuotaExceededException 85// A service limit was exceeded. 86// 87// * AccessDeniedException 88// You do not have sufficient access to perform this action. 89// 90// * ResourceNotFoundException 91// The specified resource could not be found. 92// 93// * ConflictException 94// There was a conflict processing the request. Updating or deleting the resource 95// can cause an inconsistent state. 96// 97// * ThrottlingException 98// The request was denied due to request throttling. 99// 100// * InternalServerException 101// The request has failed due to an internal error. 102// 103// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/AssociateCustomerGateway 104func (c *NetworkManager) AssociateCustomerGateway(input *AssociateCustomerGatewayInput) (*AssociateCustomerGatewayOutput, error) { 105 req, out := c.AssociateCustomerGatewayRequest(input) 106 return out, req.Send() 107} 108 109// AssociateCustomerGatewayWithContext is the same as AssociateCustomerGateway with the addition of 110// the ability to pass a context and additional request options. 111// 112// See AssociateCustomerGateway for details on how to use this API operation. 113// 114// The context must be non-nil and will be used for request cancellation. If 115// the context is nil a panic will occur. In the future the SDK may create 116// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 117// for more information on using Contexts. 118func (c *NetworkManager) AssociateCustomerGatewayWithContext(ctx aws.Context, input *AssociateCustomerGatewayInput, opts ...request.Option) (*AssociateCustomerGatewayOutput, error) { 119 req, out := c.AssociateCustomerGatewayRequest(input) 120 req.SetContext(ctx) 121 req.ApplyOptions(opts...) 122 return out, req.Send() 123} 124 125const opAssociateLink = "AssociateLink" 126 127// AssociateLinkRequest generates a "aws/request.Request" representing the 128// client's request for the AssociateLink operation. The "output" return 129// value will be populated with the request's response once the request completes 130// successfully. 131// 132// Use "Send" method on the returned Request to send the API call to the service. 133// the "output" return value is not valid until after Send returns without error. 134// 135// See AssociateLink for more information on using the AssociateLink 136// API call, and error handling. 137// 138// This method is useful when you want to inject custom logic or configuration 139// into the SDK's request lifecycle. Such as custom headers, or retry logic. 140// 141// 142// // Example sending a request using the AssociateLinkRequest method. 143// req, resp := client.AssociateLinkRequest(params) 144// 145// err := req.Send() 146// if err == nil { // resp is now filled 147// fmt.Println(resp) 148// } 149// 150// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/AssociateLink 151func (c *NetworkManager) AssociateLinkRequest(input *AssociateLinkInput) (req *request.Request, output *AssociateLinkOutput) { 152 op := &request.Operation{ 153 Name: opAssociateLink, 154 HTTPMethod: "POST", 155 HTTPPath: "/global-networks/{globalNetworkId}/link-associations", 156 } 157 158 if input == nil { 159 input = &AssociateLinkInput{} 160 } 161 162 output = &AssociateLinkOutput{} 163 req = c.newRequest(op, input, output) 164 return 165} 166 167// AssociateLink API operation for AWS Network Manager. 168// 169// Associates a link to a device. A device can be associated to multiple links 170// and a link can be associated to multiple devices. The device and link must 171// be in the same global network and the same site. 172// 173// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 174// with awserr.Error's Code and Message methods to get detailed information about 175// the error. 176// 177// See the AWS API reference guide for AWS Network Manager's 178// API operation AssociateLink for usage and error information. 179// 180// Returned Error Types: 181// * ValidationException 182// The input fails to satisfy the constraints. 183// 184// * ServiceQuotaExceededException 185// A service limit was exceeded. 186// 187// * AccessDeniedException 188// You do not have sufficient access to perform this action. 189// 190// * ResourceNotFoundException 191// The specified resource could not be found. 192// 193// * ConflictException 194// There was a conflict processing the request. Updating or deleting the resource 195// can cause an inconsistent state. 196// 197// * ThrottlingException 198// The request was denied due to request throttling. 199// 200// * InternalServerException 201// The request has failed due to an internal error. 202// 203// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/AssociateLink 204func (c *NetworkManager) AssociateLink(input *AssociateLinkInput) (*AssociateLinkOutput, error) { 205 req, out := c.AssociateLinkRequest(input) 206 return out, req.Send() 207} 208 209// AssociateLinkWithContext is the same as AssociateLink with the addition of 210// the ability to pass a context and additional request options. 211// 212// See AssociateLink for details on how to use this API operation. 213// 214// The context must be non-nil and will be used for request cancellation. If 215// the context is nil a panic will occur. In the future the SDK may create 216// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 217// for more information on using Contexts. 218func (c *NetworkManager) AssociateLinkWithContext(ctx aws.Context, input *AssociateLinkInput, opts ...request.Option) (*AssociateLinkOutput, error) { 219 req, out := c.AssociateLinkRequest(input) 220 req.SetContext(ctx) 221 req.ApplyOptions(opts...) 222 return out, req.Send() 223} 224 225const opCreateDevice = "CreateDevice" 226 227// CreateDeviceRequest generates a "aws/request.Request" representing the 228// client's request for the CreateDevice operation. The "output" return 229// value will be populated with the request's response once the request completes 230// successfully. 231// 232// Use "Send" method on the returned Request to send the API call to the service. 233// the "output" return value is not valid until after Send returns without error. 234// 235// See CreateDevice for more information on using the CreateDevice 236// API call, and error handling. 237// 238// This method is useful when you want to inject custom logic or configuration 239// into the SDK's request lifecycle. Such as custom headers, or retry logic. 240// 241// 242// // Example sending a request using the CreateDeviceRequest method. 243// req, resp := client.CreateDeviceRequest(params) 244// 245// err := req.Send() 246// if err == nil { // resp is now filled 247// fmt.Println(resp) 248// } 249// 250// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/CreateDevice 251func (c *NetworkManager) CreateDeviceRequest(input *CreateDeviceInput) (req *request.Request, output *CreateDeviceOutput) { 252 op := &request.Operation{ 253 Name: opCreateDevice, 254 HTTPMethod: "POST", 255 HTTPPath: "/global-networks/{globalNetworkId}/devices", 256 } 257 258 if input == nil { 259 input = &CreateDeviceInput{} 260 } 261 262 output = &CreateDeviceOutput{} 263 req = c.newRequest(op, input, output) 264 return 265} 266 267// CreateDevice API operation for AWS Network Manager. 268// 269// Creates a new device in a global network. If you specify both a site ID and 270// a location, the location of the site is used for visualization in the Network 271// Manager console. 272// 273// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 274// with awserr.Error's Code and Message methods to get detailed information about 275// the error. 276// 277// See the AWS API reference guide for AWS Network Manager's 278// API operation CreateDevice for usage and error information. 279// 280// Returned Error Types: 281// * ValidationException 282// The input fails to satisfy the constraints. 283// 284// * ServiceQuotaExceededException 285// A service limit was exceeded. 286// 287// * AccessDeniedException 288// You do not have sufficient access to perform this action. 289// 290// * ResourceNotFoundException 291// The specified resource could not be found. 292// 293// * ConflictException 294// There was a conflict processing the request. Updating or deleting the resource 295// can cause an inconsistent state. 296// 297// * ThrottlingException 298// The request was denied due to request throttling. 299// 300// * InternalServerException 301// The request has failed due to an internal error. 302// 303// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/CreateDevice 304func (c *NetworkManager) CreateDevice(input *CreateDeviceInput) (*CreateDeviceOutput, error) { 305 req, out := c.CreateDeviceRequest(input) 306 return out, req.Send() 307} 308 309// CreateDeviceWithContext is the same as CreateDevice with the addition of 310// the ability to pass a context and additional request options. 311// 312// See CreateDevice for details on how to use this API operation. 313// 314// The context must be non-nil and will be used for request cancellation. If 315// the context is nil a panic will occur. In the future the SDK may create 316// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 317// for more information on using Contexts. 318func (c *NetworkManager) CreateDeviceWithContext(ctx aws.Context, input *CreateDeviceInput, opts ...request.Option) (*CreateDeviceOutput, error) { 319 req, out := c.CreateDeviceRequest(input) 320 req.SetContext(ctx) 321 req.ApplyOptions(opts...) 322 return out, req.Send() 323} 324 325const opCreateGlobalNetwork = "CreateGlobalNetwork" 326 327// CreateGlobalNetworkRequest generates a "aws/request.Request" representing the 328// client's request for the CreateGlobalNetwork operation. The "output" return 329// value will be populated with the request's response once the request completes 330// successfully. 331// 332// Use "Send" method on the returned Request to send the API call to the service. 333// the "output" return value is not valid until after Send returns without error. 334// 335// See CreateGlobalNetwork for more information on using the CreateGlobalNetwork 336// API call, and error handling. 337// 338// This method is useful when you want to inject custom logic or configuration 339// into the SDK's request lifecycle. Such as custom headers, or retry logic. 340// 341// 342// // Example sending a request using the CreateGlobalNetworkRequest method. 343// req, resp := client.CreateGlobalNetworkRequest(params) 344// 345// err := req.Send() 346// if err == nil { // resp is now filled 347// fmt.Println(resp) 348// } 349// 350// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/CreateGlobalNetwork 351func (c *NetworkManager) CreateGlobalNetworkRequest(input *CreateGlobalNetworkInput) (req *request.Request, output *CreateGlobalNetworkOutput) { 352 op := &request.Operation{ 353 Name: opCreateGlobalNetwork, 354 HTTPMethod: "POST", 355 HTTPPath: "/global-networks", 356 } 357 358 if input == nil { 359 input = &CreateGlobalNetworkInput{} 360 } 361 362 output = &CreateGlobalNetworkOutput{} 363 req = c.newRequest(op, input, output) 364 return 365} 366 367// CreateGlobalNetwork API operation for AWS Network Manager. 368// 369// Creates a new, empty global network. 370// 371// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 372// with awserr.Error's Code and Message methods to get detailed information about 373// the error. 374// 375// See the AWS API reference guide for AWS Network Manager's 376// API operation CreateGlobalNetwork for usage and error information. 377// 378// Returned Error Types: 379// * ValidationException 380// The input fails to satisfy the constraints. 381// 382// * ServiceQuotaExceededException 383// A service limit was exceeded. 384// 385// * AccessDeniedException 386// You do not have sufficient access to perform this action. 387// 388// * ConflictException 389// There was a conflict processing the request. Updating or deleting the resource 390// can cause an inconsistent state. 391// 392// * ThrottlingException 393// The request was denied due to request throttling. 394// 395// * InternalServerException 396// The request has failed due to an internal error. 397// 398// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/CreateGlobalNetwork 399func (c *NetworkManager) CreateGlobalNetwork(input *CreateGlobalNetworkInput) (*CreateGlobalNetworkOutput, error) { 400 req, out := c.CreateGlobalNetworkRequest(input) 401 return out, req.Send() 402} 403 404// CreateGlobalNetworkWithContext is the same as CreateGlobalNetwork with the addition of 405// the ability to pass a context and additional request options. 406// 407// See CreateGlobalNetwork for details on how to use this API operation. 408// 409// The context must be non-nil and will be used for request cancellation. If 410// the context is nil a panic will occur. In the future the SDK may create 411// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 412// for more information on using Contexts. 413func (c *NetworkManager) CreateGlobalNetworkWithContext(ctx aws.Context, input *CreateGlobalNetworkInput, opts ...request.Option) (*CreateGlobalNetworkOutput, error) { 414 req, out := c.CreateGlobalNetworkRequest(input) 415 req.SetContext(ctx) 416 req.ApplyOptions(opts...) 417 return out, req.Send() 418} 419 420const opCreateLink = "CreateLink" 421 422// CreateLinkRequest generates a "aws/request.Request" representing the 423// client's request for the CreateLink operation. The "output" return 424// value will be populated with the request's response once the request completes 425// successfully. 426// 427// Use "Send" method on the returned Request to send the API call to the service. 428// the "output" return value is not valid until after Send returns without error. 429// 430// See CreateLink for more information on using the CreateLink 431// API call, and error handling. 432// 433// This method is useful when you want to inject custom logic or configuration 434// into the SDK's request lifecycle. Such as custom headers, or retry logic. 435// 436// 437// // Example sending a request using the CreateLinkRequest method. 438// req, resp := client.CreateLinkRequest(params) 439// 440// err := req.Send() 441// if err == nil { // resp is now filled 442// fmt.Println(resp) 443// } 444// 445// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/CreateLink 446func (c *NetworkManager) CreateLinkRequest(input *CreateLinkInput) (req *request.Request, output *CreateLinkOutput) { 447 op := &request.Operation{ 448 Name: opCreateLink, 449 HTTPMethod: "POST", 450 HTTPPath: "/global-networks/{globalNetworkId}/links", 451 } 452 453 if input == nil { 454 input = &CreateLinkInput{} 455 } 456 457 output = &CreateLinkOutput{} 458 req = c.newRequest(op, input, output) 459 return 460} 461 462// CreateLink API operation for AWS Network Manager. 463// 464// Creates a new link for a specified site. 465// 466// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 467// with awserr.Error's Code and Message methods to get detailed information about 468// the error. 469// 470// See the AWS API reference guide for AWS Network Manager's 471// API operation CreateLink for usage and error information. 472// 473// Returned Error Types: 474// * ValidationException 475// The input fails to satisfy the constraints. 476// 477// * ServiceQuotaExceededException 478// A service limit was exceeded. 479// 480// * AccessDeniedException 481// You do not have sufficient access to perform this action. 482// 483// * ResourceNotFoundException 484// The specified resource could not be found. 485// 486// * ConflictException 487// There was a conflict processing the request. Updating or deleting the resource 488// can cause an inconsistent state. 489// 490// * ThrottlingException 491// The request was denied due to request throttling. 492// 493// * InternalServerException 494// The request has failed due to an internal error. 495// 496// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/CreateLink 497func (c *NetworkManager) CreateLink(input *CreateLinkInput) (*CreateLinkOutput, error) { 498 req, out := c.CreateLinkRequest(input) 499 return out, req.Send() 500} 501 502// CreateLinkWithContext is the same as CreateLink with the addition of 503// the ability to pass a context and additional request options. 504// 505// See CreateLink for details on how to use this API operation. 506// 507// The context must be non-nil and will be used for request cancellation. If 508// the context is nil a panic will occur. In the future the SDK may create 509// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 510// for more information on using Contexts. 511func (c *NetworkManager) CreateLinkWithContext(ctx aws.Context, input *CreateLinkInput, opts ...request.Option) (*CreateLinkOutput, error) { 512 req, out := c.CreateLinkRequest(input) 513 req.SetContext(ctx) 514 req.ApplyOptions(opts...) 515 return out, req.Send() 516} 517 518const opCreateSite = "CreateSite" 519 520// CreateSiteRequest generates a "aws/request.Request" representing the 521// client's request for the CreateSite operation. The "output" return 522// value will be populated with the request's response once the request completes 523// successfully. 524// 525// Use "Send" method on the returned Request to send the API call to the service. 526// the "output" return value is not valid until after Send returns without error. 527// 528// See CreateSite for more information on using the CreateSite 529// API call, and error handling. 530// 531// This method is useful when you want to inject custom logic or configuration 532// into the SDK's request lifecycle. Such as custom headers, or retry logic. 533// 534// 535// // Example sending a request using the CreateSiteRequest method. 536// req, resp := client.CreateSiteRequest(params) 537// 538// err := req.Send() 539// if err == nil { // resp is now filled 540// fmt.Println(resp) 541// } 542// 543// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/CreateSite 544func (c *NetworkManager) CreateSiteRequest(input *CreateSiteInput) (req *request.Request, output *CreateSiteOutput) { 545 op := &request.Operation{ 546 Name: opCreateSite, 547 HTTPMethod: "POST", 548 HTTPPath: "/global-networks/{globalNetworkId}/sites", 549 } 550 551 if input == nil { 552 input = &CreateSiteInput{} 553 } 554 555 output = &CreateSiteOutput{} 556 req = c.newRequest(op, input, output) 557 return 558} 559 560// CreateSite API operation for AWS Network Manager. 561// 562// Creates a new site in a global network. 563// 564// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 565// with awserr.Error's Code and Message methods to get detailed information about 566// the error. 567// 568// See the AWS API reference guide for AWS Network Manager's 569// API operation CreateSite for usage and error information. 570// 571// Returned Error Types: 572// * ValidationException 573// The input fails to satisfy the constraints. 574// 575// * ServiceQuotaExceededException 576// A service limit was exceeded. 577// 578// * AccessDeniedException 579// You do not have sufficient access to perform this action. 580// 581// * ResourceNotFoundException 582// The specified resource could not be found. 583// 584// * ConflictException 585// There was a conflict processing the request. Updating or deleting the resource 586// can cause an inconsistent state. 587// 588// * ThrottlingException 589// The request was denied due to request throttling. 590// 591// * InternalServerException 592// The request has failed due to an internal error. 593// 594// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/CreateSite 595func (c *NetworkManager) CreateSite(input *CreateSiteInput) (*CreateSiteOutput, error) { 596 req, out := c.CreateSiteRequest(input) 597 return out, req.Send() 598} 599 600// CreateSiteWithContext is the same as CreateSite with the addition of 601// the ability to pass a context and additional request options. 602// 603// See CreateSite for details on how to use this API operation. 604// 605// The context must be non-nil and will be used for request cancellation. If 606// the context is nil a panic will occur. In the future the SDK may create 607// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 608// for more information on using Contexts. 609func (c *NetworkManager) CreateSiteWithContext(ctx aws.Context, input *CreateSiteInput, opts ...request.Option) (*CreateSiteOutput, error) { 610 req, out := c.CreateSiteRequest(input) 611 req.SetContext(ctx) 612 req.ApplyOptions(opts...) 613 return out, req.Send() 614} 615 616const opDeleteDevice = "DeleteDevice" 617 618// DeleteDeviceRequest generates a "aws/request.Request" representing the 619// client's request for the DeleteDevice operation. The "output" return 620// value will be populated with the request's response once the request completes 621// successfully. 622// 623// Use "Send" method on the returned Request to send the API call to the service. 624// the "output" return value is not valid until after Send returns without error. 625// 626// See DeleteDevice for more information on using the DeleteDevice 627// API call, and error handling. 628// 629// This method is useful when you want to inject custom logic or configuration 630// into the SDK's request lifecycle. Such as custom headers, or retry logic. 631// 632// 633// // Example sending a request using the DeleteDeviceRequest method. 634// req, resp := client.DeleteDeviceRequest(params) 635// 636// err := req.Send() 637// if err == nil { // resp is now filled 638// fmt.Println(resp) 639// } 640// 641// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/DeleteDevice 642func (c *NetworkManager) DeleteDeviceRequest(input *DeleteDeviceInput) (req *request.Request, output *DeleteDeviceOutput) { 643 op := &request.Operation{ 644 Name: opDeleteDevice, 645 HTTPMethod: "DELETE", 646 HTTPPath: "/global-networks/{globalNetworkId}/devices/{deviceId}", 647 } 648 649 if input == nil { 650 input = &DeleteDeviceInput{} 651 } 652 653 output = &DeleteDeviceOutput{} 654 req = c.newRequest(op, input, output) 655 return 656} 657 658// DeleteDevice API operation for AWS Network Manager. 659// 660// Deletes an existing device. You must first disassociate the device from any 661// links and customer gateways. 662// 663// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 664// with awserr.Error's Code and Message methods to get detailed information about 665// the error. 666// 667// See the AWS API reference guide for AWS Network Manager's 668// API operation DeleteDevice for usage and error information. 669// 670// Returned Error Types: 671// * ValidationException 672// The input fails to satisfy the constraints. 673// 674// * AccessDeniedException 675// You do not have sufficient access to perform this action. 676// 677// * ResourceNotFoundException 678// The specified resource could not be found. 679// 680// * ConflictException 681// There was a conflict processing the request. Updating or deleting the resource 682// can cause an inconsistent state. 683// 684// * ThrottlingException 685// The request was denied due to request throttling. 686// 687// * InternalServerException 688// The request has failed due to an internal error. 689// 690// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/DeleteDevice 691func (c *NetworkManager) DeleteDevice(input *DeleteDeviceInput) (*DeleteDeviceOutput, error) { 692 req, out := c.DeleteDeviceRequest(input) 693 return out, req.Send() 694} 695 696// DeleteDeviceWithContext is the same as DeleteDevice with the addition of 697// the ability to pass a context and additional request options. 698// 699// See DeleteDevice for details on how to use this API operation. 700// 701// The context must be non-nil and will be used for request cancellation. If 702// the context is nil a panic will occur. In the future the SDK may create 703// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 704// for more information on using Contexts. 705func (c *NetworkManager) DeleteDeviceWithContext(ctx aws.Context, input *DeleteDeviceInput, opts ...request.Option) (*DeleteDeviceOutput, error) { 706 req, out := c.DeleteDeviceRequest(input) 707 req.SetContext(ctx) 708 req.ApplyOptions(opts...) 709 return out, req.Send() 710} 711 712const opDeleteGlobalNetwork = "DeleteGlobalNetwork" 713 714// DeleteGlobalNetworkRequest generates a "aws/request.Request" representing the 715// client's request for the DeleteGlobalNetwork operation. The "output" return 716// value will be populated with the request's response once the request completes 717// successfully. 718// 719// Use "Send" method on the returned Request to send the API call to the service. 720// the "output" return value is not valid until after Send returns without error. 721// 722// See DeleteGlobalNetwork for more information on using the DeleteGlobalNetwork 723// API call, and error handling. 724// 725// This method is useful when you want to inject custom logic or configuration 726// into the SDK's request lifecycle. Such as custom headers, or retry logic. 727// 728// 729// // Example sending a request using the DeleteGlobalNetworkRequest method. 730// req, resp := client.DeleteGlobalNetworkRequest(params) 731// 732// err := req.Send() 733// if err == nil { // resp is now filled 734// fmt.Println(resp) 735// } 736// 737// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/DeleteGlobalNetwork 738func (c *NetworkManager) DeleteGlobalNetworkRequest(input *DeleteGlobalNetworkInput) (req *request.Request, output *DeleteGlobalNetworkOutput) { 739 op := &request.Operation{ 740 Name: opDeleteGlobalNetwork, 741 HTTPMethod: "DELETE", 742 HTTPPath: "/global-networks/{globalNetworkId}", 743 } 744 745 if input == nil { 746 input = &DeleteGlobalNetworkInput{} 747 } 748 749 output = &DeleteGlobalNetworkOutput{} 750 req = c.newRequest(op, input, output) 751 return 752} 753 754// DeleteGlobalNetwork API operation for AWS Network Manager. 755// 756// Deletes an existing global network. You must first delete all global network 757// objects (devices, links, and sites) and deregister all transit gateways. 758// 759// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 760// with awserr.Error's Code and Message methods to get detailed information about 761// the error. 762// 763// See the AWS API reference guide for AWS Network Manager's 764// API operation DeleteGlobalNetwork for usage and error information. 765// 766// Returned Error Types: 767// * ValidationException 768// The input fails to satisfy the constraints. 769// 770// * AccessDeniedException 771// You do not have sufficient access to perform this action. 772// 773// * ResourceNotFoundException 774// The specified resource could not be found. 775// 776// * ConflictException 777// There was a conflict processing the request. Updating or deleting the resource 778// can cause an inconsistent state. 779// 780// * ThrottlingException 781// The request was denied due to request throttling. 782// 783// * InternalServerException 784// The request has failed due to an internal error. 785// 786// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/DeleteGlobalNetwork 787func (c *NetworkManager) DeleteGlobalNetwork(input *DeleteGlobalNetworkInput) (*DeleteGlobalNetworkOutput, error) { 788 req, out := c.DeleteGlobalNetworkRequest(input) 789 return out, req.Send() 790} 791 792// DeleteGlobalNetworkWithContext is the same as DeleteGlobalNetwork with the addition of 793// the ability to pass a context and additional request options. 794// 795// See DeleteGlobalNetwork for details on how to use this API operation. 796// 797// The context must be non-nil and will be used for request cancellation. If 798// the context is nil a panic will occur. In the future the SDK may create 799// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 800// for more information on using Contexts. 801func (c *NetworkManager) DeleteGlobalNetworkWithContext(ctx aws.Context, input *DeleteGlobalNetworkInput, opts ...request.Option) (*DeleteGlobalNetworkOutput, error) { 802 req, out := c.DeleteGlobalNetworkRequest(input) 803 req.SetContext(ctx) 804 req.ApplyOptions(opts...) 805 return out, req.Send() 806} 807 808const opDeleteLink = "DeleteLink" 809 810// DeleteLinkRequest generates a "aws/request.Request" representing the 811// client's request for the DeleteLink operation. The "output" return 812// value will be populated with the request's response once the request completes 813// successfully. 814// 815// Use "Send" method on the returned Request to send the API call to the service. 816// the "output" return value is not valid until after Send returns without error. 817// 818// See DeleteLink for more information on using the DeleteLink 819// API call, and error handling. 820// 821// This method is useful when you want to inject custom logic or configuration 822// into the SDK's request lifecycle. Such as custom headers, or retry logic. 823// 824// 825// // Example sending a request using the DeleteLinkRequest method. 826// req, resp := client.DeleteLinkRequest(params) 827// 828// err := req.Send() 829// if err == nil { // resp is now filled 830// fmt.Println(resp) 831// } 832// 833// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/DeleteLink 834func (c *NetworkManager) DeleteLinkRequest(input *DeleteLinkInput) (req *request.Request, output *DeleteLinkOutput) { 835 op := &request.Operation{ 836 Name: opDeleteLink, 837 HTTPMethod: "DELETE", 838 HTTPPath: "/global-networks/{globalNetworkId}/links/{linkId}", 839 } 840 841 if input == nil { 842 input = &DeleteLinkInput{} 843 } 844 845 output = &DeleteLinkOutput{} 846 req = c.newRequest(op, input, output) 847 return 848} 849 850// DeleteLink API operation for AWS Network Manager. 851// 852// Deletes an existing link. You must first disassociate the link from any devices 853// and customer gateways. 854// 855// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 856// with awserr.Error's Code and Message methods to get detailed information about 857// the error. 858// 859// See the AWS API reference guide for AWS Network Manager's 860// API operation DeleteLink for usage and error information. 861// 862// Returned Error Types: 863// * ValidationException 864// The input fails to satisfy the constraints. 865// 866// * AccessDeniedException 867// You do not have sufficient access to perform this action. 868// 869// * ResourceNotFoundException 870// The specified resource could not be found. 871// 872// * ConflictException 873// There was a conflict processing the request. Updating or deleting the resource 874// can cause an inconsistent state. 875// 876// * ThrottlingException 877// The request was denied due to request throttling. 878// 879// * InternalServerException 880// The request has failed due to an internal error. 881// 882// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/DeleteLink 883func (c *NetworkManager) DeleteLink(input *DeleteLinkInput) (*DeleteLinkOutput, error) { 884 req, out := c.DeleteLinkRequest(input) 885 return out, req.Send() 886} 887 888// DeleteLinkWithContext is the same as DeleteLink with the addition of 889// the ability to pass a context and additional request options. 890// 891// See DeleteLink for details on how to use this API operation. 892// 893// The context must be non-nil and will be used for request cancellation. If 894// the context is nil a panic will occur. In the future the SDK may create 895// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 896// for more information on using Contexts. 897func (c *NetworkManager) DeleteLinkWithContext(ctx aws.Context, input *DeleteLinkInput, opts ...request.Option) (*DeleteLinkOutput, error) { 898 req, out := c.DeleteLinkRequest(input) 899 req.SetContext(ctx) 900 req.ApplyOptions(opts...) 901 return out, req.Send() 902} 903 904const opDeleteSite = "DeleteSite" 905 906// DeleteSiteRequest generates a "aws/request.Request" representing the 907// client's request for the DeleteSite operation. The "output" return 908// value will be populated with the request's response once the request completes 909// successfully. 910// 911// Use "Send" method on the returned Request to send the API call to the service. 912// the "output" return value is not valid until after Send returns without error. 913// 914// See DeleteSite for more information on using the DeleteSite 915// API call, and error handling. 916// 917// This method is useful when you want to inject custom logic or configuration 918// into the SDK's request lifecycle. Such as custom headers, or retry logic. 919// 920// 921// // Example sending a request using the DeleteSiteRequest method. 922// req, resp := client.DeleteSiteRequest(params) 923// 924// err := req.Send() 925// if err == nil { // resp is now filled 926// fmt.Println(resp) 927// } 928// 929// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/DeleteSite 930func (c *NetworkManager) DeleteSiteRequest(input *DeleteSiteInput) (req *request.Request, output *DeleteSiteOutput) { 931 op := &request.Operation{ 932 Name: opDeleteSite, 933 HTTPMethod: "DELETE", 934 HTTPPath: "/global-networks/{globalNetworkId}/sites/{siteId}", 935 } 936 937 if input == nil { 938 input = &DeleteSiteInput{} 939 } 940 941 output = &DeleteSiteOutput{} 942 req = c.newRequest(op, input, output) 943 return 944} 945 946// DeleteSite API operation for AWS Network Manager. 947// 948// Deletes an existing site. The site cannot be associated with any device or 949// link. 950// 951// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 952// with awserr.Error's Code and Message methods to get detailed information about 953// the error. 954// 955// See the AWS API reference guide for AWS Network Manager's 956// API operation DeleteSite for usage and error information. 957// 958// Returned Error Types: 959// * ValidationException 960// The input fails to satisfy the constraints. 961// 962// * AccessDeniedException 963// You do not have sufficient access to perform this action. 964// 965// * ResourceNotFoundException 966// The specified resource could not be found. 967// 968// * ConflictException 969// There was a conflict processing the request. Updating or deleting the resource 970// can cause an inconsistent state. 971// 972// * ThrottlingException 973// The request was denied due to request throttling. 974// 975// * InternalServerException 976// The request has failed due to an internal error. 977// 978// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/DeleteSite 979func (c *NetworkManager) DeleteSite(input *DeleteSiteInput) (*DeleteSiteOutput, error) { 980 req, out := c.DeleteSiteRequest(input) 981 return out, req.Send() 982} 983 984// DeleteSiteWithContext is the same as DeleteSite with the addition of 985// the ability to pass a context and additional request options. 986// 987// See DeleteSite for details on how to use this API operation. 988// 989// The context must be non-nil and will be used for request cancellation. If 990// the context is nil a panic will occur. In the future the SDK may create 991// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 992// for more information on using Contexts. 993func (c *NetworkManager) DeleteSiteWithContext(ctx aws.Context, input *DeleteSiteInput, opts ...request.Option) (*DeleteSiteOutput, error) { 994 req, out := c.DeleteSiteRequest(input) 995 req.SetContext(ctx) 996 req.ApplyOptions(opts...) 997 return out, req.Send() 998} 999 1000const opDeregisterTransitGateway = "DeregisterTransitGateway" 1001 1002// DeregisterTransitGatewayRequest generates a "aws/request.Request" representing the 1003// client's request for the DeregisterTransitGateway operation. The "output" return 1004// value will be populated with the request's response once the request completes 1005// successfully. 1006// 1007// Use "Send" method on the returned Request to send the API call to the service. 1008// the "output" return value is not valid until after Send returns without error. 1009// 1010// See DeregisterTransitGateway for more information on using the DeregisterTransitGateway 1011// API call, and error handling. 1012// 1013// This method is useful when you want to inject custom logic or configuration 1014// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1015// 1016// 1017// // Example sending a request using the DeregisterTransitGatewayRequest method. 1018// req, resp := client.DeregisterTransitGatewayRequest(params) 1019// 1020// err := req.Send() 1021// if err == nil { // resp is now filled 1022// fmt.Println(resp) 1023// } 1024// 1025// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/DeregisterTransitGateway 1026func (c *NetworkManager) DeregisterTransitGatewayRequest(input *DeregisterTransitGatewayInput) (req *request.Request, output *DeregisterTransitGatewayOutput) { 1027 op := &request.Operation{ 1028 Name: opDeregisterTransitGateway, 1029 HTTPMethod: "DELETE", 1030 HTTPPath: "/global-networks/{globalNetworkId}/transit-gateway-registrations/{transitGatewayArn}", 1031 } 1032 1033 if input == nil { 1034 input = &DeregisterTransitGatewayInput{} 1035 } 1036 1037 output = &DeregisterTransitGatewayOutput{} 1038 req = c.newRequest(op, input, output) 1039 return 1040} 1041 1042// DeregisterTransitGateway API operation for AWS Network Manager. 1043// 1044// Deregisters a transit gateway from your global network. This action does 1045// not delete your transit gateway, or modify any of its attachments. This action 1046// removes any customer gateway associations. 1047// 1048// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1049// with awserr.Error's Code and Message methods to get detailed information about 1050// the error. 1051// 1052// See the AWS API reference guide for AWS Network Manager's 1053// API operation DeregisterTransitGateway for usage and error information. 1054// 1055// Returned Error Types: 1056// * ValidationException 1057// The input fails to satisfy the constraints. 1058// 1059// * AccessDeniedException 1060// You do not have sufficient access to perform this action. 1061// 1062// * ResourceNotFoundException 1063// The specified resource could not be found. 1064// 1065// * ConflictException 1066// There was a conflict processing the request. Updating or deleting the resource 1067// can cause an inconsistent state. 1068// 1069// * ThrottlingException 1070// The request was denied due to request throttling. 1071// 1072// * InternalServerException 1073// The request has failed due to an internal error. 1074// 1075// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/DeregisterTransitGateway 1076func (c *NetworkManager) DeregisterTransitGateway(input *DeregisterTransitGatewayInput) (*DeregisterTransitGatewayOutput, error) { 1077 req, out := c.DeregisterTransitGatewayRequest(input) 1078 return out, req.Send() 1079} 1080 1081// DeregisterTransitGatewayWithContext is the same as DeregisterTransitGateway with the addition of 1082// the ability to pass a context and additional request options. 1083// 1084// See DeregisterTransitGateway for details on how to use this API operation. 1085// 1086// The context must be non-nil and will be used for request cancellation. If 1087// the context is nil a panic will occur. In the future the SDK may create 1088// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1089// for more information on using Contexts. 1090func (c *NetworkManager) DeregisterTransitGatewayWithContext(ctx aws.Context, input *DeregisterTransitGatewayInput, opts ...request.Option) (*DeregisterTransitGatewayOutput, error) { 1091 req, out := c.DeregisterTransitGatewayRequest(input) 1092 req.SetContext(ctx) 1093 req.ApplyOptions(opts...) 1094 return out, req.Send() 1095} 1096 1097const opDescribeGlobalNetworks = "DescribeGlobalNetworks" 1098 1099// DescribeGlobalNetworksRequest generates a "aws/request.Request" representing the 1100// client's request for the DescribeGlobalNetworks operation. The "output" return 1101// value will be populated with the request's response once the request completes 1102// successfully. 1103// 1104// Use "Send" method on the returned Request to send the API call to the service. 1105// the "output" return value is not valid until after Send returns without error. 1106// 1107// See DescribeGlobalNetworks for more information on using the DescribeGlobalNetworks 1108// API call, and error handling. 1109// 1110// This method is useful when you want to inject custom logic or configuration 1111// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1112// 1113// 1114// // Example sending a request using the DescribeGlobalNetworksRequest method. 1115// req, resp := client.DescribeGlobalNetworksRequest(params) 1116// 1117// err := req.Send() 1118// if err == nil { // resp is now filled 1119// fmt.Println(resp) 1120// } 1121// 1122// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/DescribeGlobalNetworks 1123func (c *NetworkManager) DescribeGlobalNetworksRequest(input *DescribeGlobalNetworksInput) (req *request.Request, output *DescribeGlobalNetworksOutput) { 1124 op := &request.Operation{ 1125 Name: opDescribeGlobalNetworks, 1126 HTTPMethod: "GET", 1127 HTTPPath: "/global-networks", 1128 Paginator: &request.Paginator{ 1129 InputTokens: []string{"NextToken"}, 1130 OutputTokens: []string{"NextToken"}, 1131 LimitToken: "MaxResults", 1132 TruncationToken: "", 1133 }, 1134 } 1135 1136 if input == nil { 1137 input = &DescribeGlobalNetworksInput{} 1138 } 1139 1140 output = &DescribeGlobalNetworksOutput{} 1141 req = c.newRequest(op, input, output) 1142 return 1143} 1144 1145// DescribeGlobalNetworks API operation for AWS Network Manager. 1146// 1147// Describes one or more global networks. By default, all global networks are 1148// described. To describe the objects in your global network, you must use the 1149// appropriate Get* action. For example, to list the transit gateways in your 1150// global network, use GetTransitGatewayRegistrations. 1151// 1152// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1153// with awserr.Error's Code and Message methods to get detailed information about 1154// the error. 1155// 1156// See the AWS API reference guide for AWS Network Manager's 1157// API operation DescribeGlobalNetworks for usage and error information. 1158// 1159// Returned Error Types: 1160// * ValidationException 1161// The input fails to satisfy the constraints. 1162// 1163// * AccessDeniedException 1164// You do not have sufficient access to perform this action. 1165// 1166// * ResourceNotFoundException 1167// The specified resource could not be found. 1168// 1169// * ThrottlingException 1170// The request was denied due to request throttling. 1171// 1172// * InternalServerException 1173// The request has failed due to an internal error. 1174// 1175// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/DescribeGlobalNetworks 1176func (c *NetworkManager) DescribeGlobalNetworks(input *DescribeGlobalNetworksInput) (*DescribeGlobalNetworksOutput, error) { 1177 req, out := c.DescribeGlobalNetworksRequest(input) 1178 return out, req.Send() 1179} 1180 1181// DescribeGlobalNetworksWithContext is the same as DescribeGlobalNetworks with the addition of 1182// the ability to pass a context and additional request options. 1183// 1184// See DescribeGlobalNetworks for details on how to use this API operation. 1185// 1186// The context must be non-nil and will be used for request cancellation. If 1187// the context is nil a panic will occur. In the future the SDK may create 1188// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1189// for more information on using Contexts. 1190func (c *NetworkManager) DescribeGlobalNetworksWithContext(ctx aws.Context, input *DescribeGlobalNetworksInput, opts ...request.Option) (*DescribeGlobalNetworksOutput, error) { 1191 req, out := c.DescribeGlobalNetworksRequest(input) 1192 req.SetContext(ctx) 1193 req.ApplyOptions(opts...) 1194 return out, req.Send() 1195} 1196 1197// DescribeGlobalNetworksPages iterates over the pages of a DescribeGlobalNetworks operation, 1198// calling the "fn" function with the response data for each page. To stop 1199// iterating, return false from the fn function. 1200// 1201// See DescribeGlobalNetworks method for more information on how to use this operation. 1202// 1203// Note: This operation can generate multiple requests to a service. 1204// 1205// // Example iterating over at most 3 pages of a DescribeGlobalNetworks operation. 1206// pageNum := 0 1207// err := client.DescribeGlobalNetworksPages(params, 1208// func(page *networkmanager.DescribeGlobalNetworksOutput, lastPage bool) bool { 1209// pageNum++ 1210// fmt.Println(page) 1211// return pageNum <= 3 1212// }) 1213// 1214func (c *NetworkManager) DescribeGlobalNetworksPages(input *DescribeGlobalNetworksInput, fn func(*DescribeGlobalNetworksOutput, bool) bool) error { 1215 return c.DescribeGlobalNetworksPagesWithContext(aws.BackgroundContext(), input, fn) 1216} 1217 1218// DescribeGlobalNetworksPagesWithContext same as DescribeGlobalNetworksPages except 1219// it takes a Context and allows setting request options on the pages. 1220// 1221// The context must be non-nil and will be used for request cancellation. If 1222// the context is nil a panic will occur. In the future the SDK may create 1223// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1224// for more information on using Contexts. 1225func (c *NetworkManager) DescribeGlobalNetworksPagesWithContext(ctx aws.Context, input *DescribeGlobalNetworksInput, fn func(*DescribeGlobalNetworksOutput, bool) bool, opts ...request.Option) error { 1226 p := request.Pagination{ 1227 NewRequest: func() (*request.Request, error) { 1228 var inCpy *DescribeGlobalNetworksInput 1229 if input != nil { 1230 tmp := *input 1231 inCpy = &tmp 1232 } 1233 req, _ := c.DescribeGlobalNetworksRequest(inCpy) 1234 req.SetContext(ctx) 1235 req.ApplyOptions(opts...) 1236 return req, nil 1237 }, 1238 } 1239 1240 for p.Next() { 1241 if !fn(p.Page().(*DescribeGlobalNetworksOutput), !p.HasNextPage()) { 1242 break 1243 } 1244 } 1245 1246 return p.Err() 1247} 1248 1249const opDisassociateCustomerGateway = "DisassociateCustomerGateway" 1250 1251// DisassociateCustomerGatewayRequest generates a "aws/request.Request" representing the 1252// client's request for the DisassociateCustomerGateway operation. The "output" return 1253// value will be populated with the request's response once the request completes 1254// successfully. 1255// 1256// Use "Send" method on the returned Request to send the API call to the service. 1257// the "output" return value is not valid until after Send returns without error. 1258// 1259// See DisassociateCustomerGateway for more information on using the DisassociateCustomerGateway 1260// API call, and error handling. 1261// 1262// This method is useful when you want to inject custom logic or configuration 1263// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1264// 1265// 1266// // Example sending a request using the DisassociateCustomerGatewayRequest method. 1267// req, resp := client.DisassociateCustomerGatewayRequest(params) 1268// 1269// err := req.Send() 1270// if err == nil { // resp is now filled 1271// fmt.Println(resp) 1272// } 1273// 1274// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/DisassociateCustomerGateway 1275func (c *NetworkManager) DisassociateCustomerGatewayRequest(input *DisassociateCustomerGatewayInput) (req *request.Request, output *DisassociateCustomerGatewayOutput) { 1276 op := &request.Operation{ 1277 Name: opDisassociateCustomerGateway, 1278 HTTPMethod: "DELETE", 1279 HTTPPath: "/global-networks/{globalNetworkId}/customer-gateway-associations/{customerGatewayArn}", 1280 } 1281 1282 if input == nil { 1283 input = &DisassociateCustomerGatewayInput{} 1284 } 1285 1286 output = &DisassociateCustomerGatewayOutput{} 1287 req = c.newRequest(op, input, output) 1288 return 1289} 1290 1291// DisassociateCustomerGateway API operation for AWS Network Manager. 1292// 1293// Disassociates a customer gateway from a device and a link. 1294// 1295// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1296// with awserr.Error's Code and Message methods to get detailed information about 1297// the error. 1298// 1299// See the AWS API reference guide for AWS Network Manager's 1300// API operation DisassociateCustomerGateway for usage and error information. 1301// 1302// Returned Error Types: 1303// * ValidationException 1304// The input fails to satisfy the constraints. 1305// 1306// * AccessDeniedException 1307// You do not have sufficient access to perform this action. 1308// 1309// * ResourceNotFoundException 1310// The specified resource could not be found. 1311// 1312// * ConflictException 1313// There was a conflict processing the request. Updating or deleting the resource 1314// can cause an inconsistent state. 1315// 1316// * ThrottlingException 1317// The request was denied due to request throttling. 1318// 1319// * InternalServerException 1320// The request has failed due to an internal error. 1321// 1322// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/DisassociateCustomerGateway 1323func (c *NetworkManager) DisassociateCustomerGateway(input *DisassociateCustomerGatewayInput) (*DisassociateCustomerGatewayOutput, error) { 1324 req, out := c.DisassociateCustomerGatewayRequest(input) 1325 return out, req.Send() 1326} 1327 1328// DisassociateCustomerGatewayWithContext is the same as DisassociateCustomerGateway with the addition of 1329// the ability to pass a context and additional request options. 1330// 1331// See DisassociateCustomerGateway for details on how to use this API operation. 1332// 1333// The context must be non-nil and will be used for request cancellation. If 1334// the context is nil a panic will occur. In the future the SDK may create 1335// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1336// for more information on using Contexts. 1337func (c *NetworkManager) DisassociateCustomerGatewayWithContext(ctx aws.Context, input *DisassociateCustomerGatewayInput, opts ...request.Option) (*DisassociateCustomerGatewayOutput, error) { 1338 req, out := c.DisassociateCustomerGatewayRequest(input) 1339 req.SetContext(ctx) 1340 req.ApplyOptions(opts...) 1341 return out, req.Send() 1342} 1343 1344const opDisassociateLink = "DisassociateLink" 1345 1346// DisassociateLinkRequest generates a "aws/request.Request" representing the 1347// client's request for the DisassociateLink operation. The "output" return 1348// value will be populated with the request's response once the request completes 1349// successfully. 1350// 1351// Use "Send" method on the returned Request to send the API call to the service. 1352// the "output" return value is not valid until after Send returns without error. 1353// 1354// See DisassociateLink for more information on using the DisassociateLink 1355// API call, and error handling. 1356// 1357// This method is useful when you want to inject custom logic or configuration 1358// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1359// 1360// 1361// // Example sending a request using the DisassociateLinkRequest method. 1362// req, resp := client.DisassociateLinkRequest(params) 1363// 1364// err := req.Send() 1365// if err == nil { // resp is now filled 1366// fmt.Println(resp) 1367// } 1368// 1369// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/DisassociateLink 1370func (c *NetworkManager) DisassociateLinkRequest(input *DisassociateLinkInput) (req *request.Request, output *DisassociateLinkOutput) { 1371 op := &request.Operation{ 1372 Name: opDisassociateLink, 1373 HTTPMethod: "DELETE", 1374 HTTPPath: "/global-networks/{globalNetworkId}/link-associations", 1375 } 1376 1377 if input == nil { 1378 input = &DisassociateLinkInput{} 1379 } 1380 1381 output = &DisassociateLinkOutput{} 1382 req = c.newRequest(op, input, output) 1383 return 1384} 1385 1386// DisassociateLink API operation for AWS Network Manager. 1387// 1388// Disassociates an existing device from a link. You must first disassociate 1389// any customer gateways that are associated with the link. 1390// 1391// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1392// with awserr.Error's Code and Message methods to get detailed information about 1393// the error. 1394// 1395// See the AWS API reference guide for AWS Network Manager's 1396// API operation DisassociateLink for usage and error information. 1397// 1398// Returned Error Types: 1399// * ValidationException 1400// The input fails to satisfy the constraints. 1401// 1402// * AccessDeniedException 1403// You do not have sufficient access to perform this action. 1404// 1405// * ResourceNotFoundException 1406// The specified resource could not be found. 1407// 1408// * ConflictException 1409// There was a conflict processing the request. Updating or deleting the resource 1410// can cause an inconsistent state. 1411// 1412// * ThrottlingException 1413// The request was denied due to request throttling. 1414// 1415// * InternalServerException 1416// The request has failed due to an internal error. 1417// 1418// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/DisassociateLink 1419func (c *NetworkManager) DisassociateLink(input *DisassociateLinkInput) (*DisassociateLinkOutput, error) { 1420 req, out := c.DisassociateLinkRequest(input) 1421 return out, req.Send() 1422} 1423 1424// DisassociateLinkWithContext is the same as DisassociateLink with the addition of 1425// the ability to pass a context and additional request options. 1426// 1427// See DisassociateLink for details on how to use this API operation. 1428// 1429// The context must be non-nil and will be used for request cancellation. If 1430// the context is nil a panic will occur. In the future the SDK may create 1431// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1432// for more information on using Contexts. 1433func (c *NetworkManager) DisassociateLinkWithContext(ctx aws.Context, input *DisassociateLinkInput, opts ...request.Option) (*DisassociateLinkOutput, error) { 1434 req, out := c.DisassociateLinkRequest(input) 1435 req.SetContext(ctx) 1436 req.ApplyOptions(opts...) 1437 return out, req.Send() 1438} 1439 1440const opGetCustomerGatewayAssociations = "GetCustomerGatewayAssociations" 1441 1442// GetCustomerGatewayAssociationsRequest generates a "aws/request.Request" representing the 1443// client's request for the GetCustomerGatewayAssociations operation. The "output" return 1444// value will be populated with the request's response once the request completes 1445// successfully. 1446// 1447// Use "Send" method on the returned Request to send the API call to the service. 1448// the "output" return value is not valid until after Send returns without error. 1449// 1450// See GetCustomerGatewayAssociations for more information on using the GetCustomerGatewayAssociations 1451// API call, and error handling. 1452// 1453// This method is useful when you want to inject custom logic or configuration 1454// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1455// 1456// 1457// // Example sending a request using the GetCustomerGatewayAssociationsRequest method. 1458// req, resp := client.GetCustomerGatewayAssociationsRequest(params) 1459// 1460// err := req.Send() 1461// if err == nil { // resp is now filled 1462// fmt.Println(resp) 1463// } 1464// 1465// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/GetCustomerGatewayAssociations 1466func (c *NetworkManager) GetCustomerGatewayAssociationsRequest(input *GetCustomerGatewayAssociationsInput) (req *request.Request, output *GetCustomerGatewayAssociationsOutput) { 1467 op := &request.Operation{ 1468 Name: opGetCustomerGatewayAssociations, 1469 HTTPMethod: "GET", 1470 HTTPPath: "/global-networks/{globalNetworkId}/customer-gateway-associations", 1471 Paginator: &request.Paginator{ 1472 InputTokens: []string{"NextToken"}, 1473 OutputTokens: []string{"NextToken"}, 1474 LimitToken: "MaxResults", 1475 TruncationToken: "", 1476 }, 1477 } 1478 1479 if input == nil { 1480 input = &GetCustomerGatewayAssociationsInput{} 1481 } 1482 1483 output = &GetCustomerGatewayAssociationsOutput{} 1484 req = c.newRequest(op, input, output) 1485 return 1486} 1487 1488// GetCustomerGatewayAssociations API operation for AWS Network Manager. 1489// 1490// Gets the association information for customer gateways that are associated 1491// with devices and links in your global network. 1492// 1493// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1494// with awserr.Error's Code and Message methods to get detailed information about 1495// the error. 1496// 1497// See the AWS API reference guide for AWS Network Manager's 1498// API operation GetCustomerGatewayAssociations for usage and error information. 1499// 1500// Returned Error Types: 1501// * ValidationException 1502// The input fails to satisfy the constraints. 1503// 1504// * AccessDeniedException 1505// You do not have sufficient access to perform this action. 1506// 1507// * ResourceNotFoundException 1508// The specified resource could not be found. 1509// 1510// * ConflictException 1511// There was a conflict processing the request. Updating or deleting the resource 1512// can cause an inconsistent state. 1513// 1514// * ThrottlingException 1515// The request was denied due to request throttling. 1516// 1517// * InternalServerException 1518// The request has failed due to an internal error. 1519// 1520// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/GetCustomerGatewayAssociations 1521func (c *NetworkManager) GetCustomerGatewayAssociations(input *GetCustomerGatewayAssociationsInput) (*GetCustomerGatewayAssociationsOutput, error) { 1522 req, out := c.GetCustomerGatewayAssociationsRequest(input) 1523 return out, req.Send() 1524} 1525 1526// GetCustomerGatewayAssociationsWithContext is the same as GetCustomerGatewayAssociations with the addition of 1527// the ability to pass a context and additional request options. 1528// 1529// See GetCustomerGatewayAssociations for details on how to use this API operation. 1530// 1531// The context must be non-nil and will be used for request cancellation. If 1532// the context is nil a panic will occur. In the future the SDK may create 1533// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1534// for more information on using Contexts. 1535func (c *NetworkManager) GetCustomerGatewayAssociationsWithContext(ctx aws.Context, input *GetCustomerGatewayAssociationsInput, opts ...request.Option) (*GetCustomerGatewayAssociationsOutput, error) { 1536 req, out := c.GetCustomerGatewayAssociationsRequest(input) 1537 req.SetContext(ctx) 1538 req.ApplyOptions(opts...) 1539 return out, req.Send() 1540} 1541 1542// GetCustomerGatewayAssociationsPages iterates over the pages of a GetCustomerGatewayAssociations operation, 1543// calling the "fn" function with the response data for each page. To stop 1544// iterating, return false from the fn function. 1545// 1546// See GetCustomerGatewayAssociations method for more information on how to use this operation. 1547// 1548// Note: This operation can generate multiple requests to a service. 1549// 1550// // Example iterating over at most 3 pages of a GetCustomerGatewayAssociations operation. 1551// pageNum := 0 1552// err := client.GetCustomerGatewayAssociationsPages(params, 1553// func(page *networkmanager.GetCustomerGatewayAssociationsOutput, lastPage bool) bool { 1554// pageNum++ 1555// fmt.Println(page) 1556// return pageNum <= 3 1557// }) 1558// 1559func (c *NetworkManager) GetCustomerGatewayAssociationsPages(input *GetCustomerGatewayAssociationsInput, fn func(*GetCustomerGatewayAssociationsOutput, bool) bool) error { 1560 return c.GetCustomerGatewayAssociationsPagesWithContext(aws.BackgroundContext(), input, fn) 1561} 1562 1563// GetCustomerGatewayAssociationsPagesWithContext same as GetCustomerGatewayAssociationsPages except 1564// it takes a Context and allows setting request options on the pages. 1565// 1566// The context must be non-nil and will be used for request cancellation. If 1567// the context is nil a panic will occur. In the future the SDK may create 1568// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1569// for more information on using Contexts. 1570func (c *NetworkManager) GetCustomerGatewayAssociationsPagesWithContext(ctx aws.Context, input *GetCustomerGatewayAssociationsInput, fn func(*GetCustomerGatewayAssociationsOutput, bool) bool, opts ...request.Option) error { 1571 p := request.Pagination{ 1572 NewRequest: func() (*request.Request, error) { 1573 var inCpy *GetCustomerGatewayAssociationsInput 1574 if input != nil { 1575 tmp := *input 1576 inCpy = &tmp 1577 } 1578 req, _ := c.GetCustomerGatewayAssociationsRequest(inCpy) 1579 req.SetContext(ctx) 1580 req.ApplyOptions(opts...) 1581 return req, nil 1582 }, 1583 } 1584 1585 for p.Next() { 1586 if !fn(p.Page().(*GetCustomerGatewayAssociationsOutput), !p.HasNextPage()) { 1587 break 1588 } 1589 } 1590 1591 return p.Err() 1592} 1593 1594const opGetDevices = "GetDevices" 1595 1596// GetDevicesRequest generates a "aws/request.Request" representing the 1597// client's request for the GetDevices operation. The "output" return 1598// value will be populated with the request's response once the request completes 1599// successfully. 1600// 1601// Use "Send" method on the returned Request to send the API call to the service. 1602// the "output" return value is not valid until after Send returns without error. 1603// 1604// See GetDevices for more information on using the GetDevices 1605// API call, and error handling. 1606// 1607// This method is useful when you want to inject custom logic or configuration 1608// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1609// 1610// 1611// // Example sending a request using the GetDevicesRequest method. 1612// req, resp := client.GetDevicesRequest(params) 1613// 1614// err := req.Send() 1615// if err == nil { // resp is now filled 1616// fmt.Println(resp) 1617// } 1618// 1619// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/GetDevices 1620func (c *NetworkManager) GetDevicesRequest(input *GetDevicesInput) (req *request.Request, output *GetDevicesOutput) { 1621 op := &request.Operation{ 1622 Name: opGetDevices, 1623 HTTPMethod: "GET", 1624 HTTPPath: "/global-networks/{globalNetworkId}/devices", 1625 Paginator: &request.Paginator{ 1626 InputTokens: []string{"NextToken"}, 1627 OutputTokens: []string{"NextToken"}, 1628 LimitToken: "MaxResults", 1629 TruncationToken: "", 1630 }, 1631 } 1632 1633 if input == nil { 1634 input = &GetDevicesInput{} 1635 } 1636 1637 output = &GetDevicesOutput{} 1638 req = c.newRequest(op, input, output) 1639 return 1640} 1641 1642// GetDevices API operation for AWS Network Manager. 1643// 1644// Gets information about one or more of your devices in a global network. 1645// 1646// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1647// with awserr.Error's Code and Message methods to get detailed information about 1648// the error. 1649// 1650// See the AWS API reference guide for AWS Network Manager's 1651// API operation GetDevices for usage and error information. 1652// 1653// Returned Error Types: 1654// * ValidationException 1655// The input fails to satisfy the constraints. 1656// 1657// * AccessDeniedException 1658// You do not have sufficient access to perform this action. 1659// 1660// * ResourceNotFoundException 1661// The specified resource could not be found. 1662// 1663// * ThrottlingException 1664// The request was denied due to request throttling. 1665// 1666// * InternalServerException 1667// The request has failed due to an internal error. 1668// 1669// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/GetDevices 1670func (c *NetworkManager) GetDevices(input *GetDevicesInput) (*GetDevicesOutput, error) { 1671 req, out := c.GetDevicesRequest(input) 1672 return out, req.Send() 1673} 1674 1675// GetDevicesWithContext is the same as GetDevices with the addition of 1676// the ability to pass a context and additional request options. 1677// 1678// See GetDevices for details on how to use this API operation. 1679// 1680// The context must be non-nil and will be used for request cancellation. If 1681// the context is nil a panic will occur. In the future the SDK may create 1682// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1683// for more information on using Contexts. 1684func (c *NetworkManager) GetDevicesWithContext(ctx aws.Context, input *GetDevicesInput, opts ...request.Option) (*GetDevicesOutput, error) { 1685 req, out := c.GetDevicesRequest(input) 1686 req.SetContext(ctx) 1687 req.ApplyOptions(opts...) 1688 return out, req.Send() 1689} 1690 1691// GetDevicesPages iterates over the pages of a GetDevices operation, 1692// calling the "fn" function with the response data for each page. To stop 1693// iterating, return false from the fn function. 1694// 1695// See GetDevices method for more information on how to use this operation. 1696// 1697// Note: This operation can generate multiple requests to a service. 1698// 1699// // Example iterating over at most 3 pages of a GetDevices operation. 1700// pageNum := 0 1701// err := client.GetDevicesPages(params, 1702// func(page *networkmanager.GetDevicesOutput, lastPage bool) bool { 1703// pageNum++ 1704// fmt.Println(page) 1705// return pageNum <= 3 1706// }) 1707// 1708func (c *NetworkManager) GetDevicesPages(input *GetDevicesInput, fn func(*GetDevicesOutput, bool) bool) error { 1709 return c.GetDevicesPagesWithContext(aws.BackgroundContext(), input, fn) 1710} 1711 1712// GetDevicesPagesWithContext same as GetDevicesPages except 1713// it takes a Context and allows setting request options on the pages. 1714// 1715// The context must be non-nil and will be used for request cancellation. If 1716// the context is nil a panic will occur. In the future the SDK may create 1717// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1718// for more information on using Contexts. 1719func (c *NetworkManager) GetDevicesPagesWithContext(ctx aws.Context, input *GetDevicesInput, fn func(*GetDevicesOutput, bool) bool, opts ...request.Option) error { 1720 p := request.Pagination{ 1721 NewRequest: func() (*request.Request, error) { 1722 var inCpy *GetDevicesInput 1723 if input != nil { 1724 tmp := *input 1725 inCpy = &tmp 1726 } 1727 req, _ := c.GetDevicesRequest(inCpy) 1728 req.SetContext(ctx) 1729 req.ApplyOptions(opts...) 1730 return req, nil 1731 }, 1732 } 1733 1734 for p.Next() { 1735 if !fn(p.Page().(*GetDevicesOutput), !p.HasNextPage()) { 1736 break 1737 } 1738 } 1739 1740 return p.Err() 1741} 1742 1743const opGetLinkAssociations = "GetLinkAssociations" 1744 1745// GetLinkAssociationsRequest generates a "aws/request.Request" representing the 1746// client's request for the GetLinkAssociations operation. The "output" return 1747// value will be populated with the request's response once the request completes 1748// successfully. 1749// 1750// Use "Send" method on the returned Request to send the API call to the service. 1751// the "output" return value is not valid until after Send returns without error. 1752// 1753// See GetLinkAssociations for more information on using the GetLinkAssociations 1754// API call, and error handling. 1755// 1756// This method is useful when you want to inject custom logic or configuration 1757// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1758// 1759// 1760// // Example sending a request using the GetLinkAssociationsRequest method. 1761// req, resp := client.GetLinkAssociationsRequest(params) 1762// 1763// err := req.Send() 1764// if err == nil { // resp is now filled 1765// fmt.Println(resp) 1766// } 1767// 1768// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/GetLinkAssociations 1769func (c *NetworkManager) GetLinkAssociationsRequest(input *GetLinkAssociationsInput) (req *request.Request, output *GetLinkAssociationsOutput) { 1770 op := &request.Operation{ 1771 Name: opGetLinkAssociations, 1772 HTTPMethod: "GET", 1773 HTTPPath: "/global-networks/{globalNetworkId}/link-associations", 1774 Paginator: &request.Paginator{ 1775 InputTokens: []string{"NextToken"}, 1776 OutputTokens: []string{"NextToken"}, 1777 LimitToken: "MaxResults", 1778 TruncationToken: "", 1779 }, 1780 } 1781 1782 if input == nil { 1783 input = &GetLinkAssociationsInput{} 1784 } 1785 1786 output = &GetLinkAssociationsOutput{} 1787 req = c.newRequest(op, input, output) 1788 return 1789} 1790 1791// GetLinkAssociations API operation for AWS Network Manager. 1792// 1793// Gets the link associations for a device or a link. Either the device ID or 1794// the link ID must be specified. 1795// 1796// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1797// with awserr.Error's Code and Message methods to get detailed information about 1798// the error. 1799// 1800// See the AWS API reference guide for AWS Network Manager's 1801// API operation GetLinkAssociations for usage and error information. 1802// 1803// Returned Error Types: 1804// * ValidationException 1805// The input fails to satisfy the constraints. 1806// 1807// * AccessDeniedException 1808// You do not have sufficient access to perform this action. 1809// 1810// * ResourceNotFoundException 1811// The specified resource could not be found. 1812// 1813// * ThrottlingException 1814// The request was denied due to request throttling. 1815// 1816// * InternalServerException 1817// The request has failed due to an internal error. 1818// 1819// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/GetLinkAssociations 1820func (c *NetworkManager) GetLinkAssociations(input *GetLinkAssociationsInput) (*GetLinkAssociationsOutput, error) { 1821 req, out := c.GetLinkAssociationsRequest(input) 1822 return out, req.Send() 1823} 1824 1825// GetLinkAssociationsWithContext is the same as GetLinkAssociations with the addition of 1826// the ability to pass a context and additional request options. 1827// 1828// See GetLinkAssociations for details on how to use this API operation. 1829// 1830// The context must be non-nil and will be used for request cancellation. If 1831// the context is nil a panic will occur. In the future the SDK may create 1832// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1833// for more information on using Contexts. 1834func (c *NetworkManager) GetLinkAssociationsWithContext(ctx aws.Context, input *GetLinkAssociationsInput, opts ...request.Option) (*GetLinkAssociationsOutput, error) { 1835 req, out := c.GetLinkAssociationsRequest(input) 1836 req.SetContext(ctx) 1837 req.ApplyOptions(opts...) 1838 return out, req.Send() 1839} 1840 1841// GetLinkAssociationsPages iterates over the pages of a GetLinkAssociations operation, 1842// calling the "fn" function with the response data for each page. To stop 1843// iterating, return false from the fn function. 1844// 1845// See GetLinkAssociations method for more information on how to use this operation. 1846// 1847// Note: This operation can generate multiple requests to a service. 1848// 1849// // Example iterating over at most 3 pages of a GetLinkAssociations operation. 1850// pageNum := 0 1851// err := client.GetLinkAssociationsPages(params, 1852// func(page *networkmanager.GetLinkAssociationsOutput, lastPage bool) bool { 1853// pageNum++ 1854// fmt.Println(page) 1855// return pageNum <= 3 1856// }) 1857// 1858func (c *NetworkManager) GetLinkAssociationsPages(input *GetLinkAssociationsInput, fn func(*GetLinkAssociationsOutput, bool) bool) error { 1859 return c.GetLinkAssociationsPagesWithContext(aws.BackgroundContext(), input, fn) 1860} 1861 1862// GetLinkAssociationsPagesWithContext same as GetLinkAssociationsPages except 1863// it takes a Context and allows setting request options on the pages. 1864// 1865// The context must be non-nil and will be used for request cancellation. If 1866// the context is nil a panic will occur. In the future the SDK may create 1867// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1868// for more information on using Contexts. 1869func (c *NetworkManager) GetLinkAssociationsPagesWithContext(ctx aws.Context, input *GetLinkAssociationsInput, fn func(*GetLinkAssociationsOutput, bool) bool, opts ...request.Option) error { 1870 p := request.Pagination{ 1871 NewRequest: func() (*request.Request, error) { 1872 var inCpy *GetLinkAssociationsInput 1873 if input != nil { 1874 tmp := *input 1875 inCpy = &tmp 1876 } 1877 req, _ := c.GetLinkAssociationsRequest(inCpy) 1878 req.SetContext(ctx) 1879 req.ApplyOptions(opts...) 1880 return req, nil 1881 }, 1882 } 1883 1884 for p.Next() { 1885 if !fn(p.Page().(*GetLinkAssociationsOutput), !p.HasNextPage()) { 1886 break 1887 } 1888 } 1889 1890 return p.Err() 1891} 1892 1893const opGetLinks = "GetLinks" 1894 1895// GetLinksRequest generates a "aws/request.Request" representing the 1896// client's request for the GetLinks operation. The "output" return 1897// value will be populated with the request's response once the request completes 1898// successfully. 1899// 1900// Use "Send" method on the returned Request to send the API call to the service. 1901// the "output" return value is not valid until after Send returns without error. 1902// 1903// See GetLinks for more information on using the GetLinks 1904// API call, and error handling. 1905// 1906// This method is useful when you want to inject custom logic or configuration 1907// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1908// 1909// 1910// // Example sending a request using the GetLinksRequest method. 1911// req, resp := client.GetLinksRequest(params) 1912// 1913// err := req.Send() 1914// if err == nil { // resp is now filled 1915// fmt.Println(resp) 1916// } 1917// 1918// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/GetLinks 1919func (c *NetworkManager) GetLinksRequest(input *GetLinksInput) (req *request.Request, output *GetLinksOutput) { 1920 op := &request.Operation{ 1921 Name: opGetLinks, 1922 HTTPMethod: "GET", 1923 HTTPPath: "/global-networks/{globalNetworkId}/links", 1924 Paginator: &request.Paginator{ 1925 InputTokens: []string{"NextToken"}, 1926 OutputTokens: []string{"NextToken"}, 1927 LimitToken: "MaxResults", 1928 TruncationToken: "", 1929 }, 1930 } 1931 1932 if input == nil { 1933 input = &GetLinksInput{} 1934 } 1935 1936 output = &GetLinksOutput{} 1937 req = c.newRequest(op, input, output) 1938 return 1939} 1940 1941// GetLinks API operation for AWS Network Manager. 1942// 1943// Gets information about one or more links in a specified global network. 1944// 1945// If you specify the site ID, you cannot specify the type or provider in the 1946// same request. You can specify the type and provider in the same request. 1947// 1948// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1949// with awserr.Error's Code and Message methods to get detailed information about 1950// the error. 1951// 1952// See the AWS API reference guide for AWS Network Manager's 1953// API operation GetLinks for usage and error information. 1954// 1955// Returned Error Types: 1956// * ValidationException 1957// The input fails to satisfy the constraints. 1958// 1959// * AccessDeniedException 1960// You do not have sufficient access to perform this action. 1961// 1962// * ResourceNotFoundException 1963// The specified resource could not be found. 1964// 1965// * ThrottlingException 1966// The request was denied due to request throttling. 1967// 1968// * InternalServerException 1969// The request has failed due to an internal error. 1970// 1971// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/GetLinks 1972func (c *NetworkManager) GetLinks(input *GetLinksInput) (*GetLinksOutput, error) { 1973 req, out := c.GetLinksRequest(input) 1974 return out, req.Send() 1975} 1976 1977// GetLinksWithContext is the same as GetLinks with the addition of 1978// the ability to pass a context and additional request options. 1979// 1980// See GetLinks for details on how to use this API operation. 1981// 1982// The context must be non-nil and will be used for request cancellation. If 1983// the context is nil a panic will occur. In the future the SDK may create 1984// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1985// for more information on using Contexts. 1986func (c *NetworkManager) GetLinksWithContext(ctx aws.Context, input *GetLinksInput, opts ...request.Option) (*GetLinksOutput, error) { 1987 req, out := c.GetLinksRequest(input) 1988 req.SetContext(ctx) 1989 req.ApplyOptions(opts...) 1990 return out, req.Send() 1991} 1992 1993// GetLinksPages iterates over the pages of a GetLinks operation, 1994// calling the "fn" function with the response data for each page. To stop 1995// iterating, return false from the fn function. 1996// 1997// See GetLinks method for more information on how to use this operation. 1998// 1999// Note: This operation can generate multiple requests to a service. 2000// 2001// // Example iterating over at most 3 pages of a GetLinks operation. 2002// pageNum := 0 2003// err := client.GetLinksPages(params, 2004// func(page *networkmanager.GetLinksOutput, lastPage bool) bool { 2005// pageNum++ 2006// fmt.Println(page) 2007// return pageNum <= 3 2008// }) 2009// 2010func (c *NetworkManager) GetLinksPages(input *GetLinksInput, fn func(*GetLinksOutput, bool) bool) error { 2011 return c.GetLinksPagesWithContext(aws.BackgroundContext(), input, fn) 2012} 2013 2014// GetLinksPagesWithContext same as GetLinksPages except 2015// it takes a Context and allows setting request options on the pages. 2016// 2017// The context must be non-nil and will be used for request cancellation. If 2018// the context is nil a panic will occur. In the future the SDK may create 2019// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2020// for more information on using Contexts. 2021func (c *NetworkManager) GetLinksPagesWithContext(ctx aws.Context, input *GetLinksInput, fn func(*GetLinksOutput, bool) bool, opts ...request.Option) error { 2022 p := request.Pagination{ 2023 NewRequest: func() (*request.Request, error) { 2024 var inCpy *GetLinksInput 2025 if input != nil { 2026 tmp := *input 2027 inCpy = &tmp 2028 } 2029 req, _ := c.GetLinksRequest(inCpy) 2030 req.SetContext(ctx) 2031 req.ApplyOptions(opts...) 2032 return req, nil 2033 }, 2034 } 2035 2036 for p.Next() { 2037 if !fn(p.Page().(*GetLinksOutput), !p.HasNextPage()) { 2038 break 2039 } 2040 } 2041 2042 return p.Err() 2043} 2044 2045const opGetSites = "GetSites" 2046 2047// GetSitesRequest generates a "aws/request.Request" representing the 2048// client's request for the GetSites operation. The "output" return 2049// value will be populated with the request's response once the request completes 2050// successfully. 2051// 2052// Use "Send" method on the returned Request to send the API call to the service. 2053// the "output" return value is not valid until after Send returns without error. 2054// 2055// See GetSites for more information on using the GetSites 2056// API call, and error handling. 2057// 2058// This method is useful when you want to inject custom logic or configuration 2059// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2060// 2061// 2062// // Example sending a request using the GetSitesRequest method. 2063// req, resp := client.GetSitesRequest(params) 2064// 2065// err := req.Send() 2066// if err == nil { // resp is now filled 2067// fmt.Println(resp) 2068// } 2069// 2070// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/GetSites 2071func (c *NetworkManager) GetSitesRequest(input *GetSitesInput) (req *request.Request, output *GetSitesOutput) { 2072 op := &request.Operation{ 2073 Name: opGetSites, 2074 HTTPMethod: "GET", 2075 HTTPPath: "/global-networks/{globalNetworkId}/sites", 2076 Paginator: &request.Paginator{ 2077 InputTokens: []string{"NextToken"}, 2078 OutputTokens: []string{"NextToken"}, 2079 LimitToken: "MaxResults", 2080 TruncationToken: "", 2081 }, 2082 } 2083 2084 if input == nil { 2085 input = &GetSitesInput{} 2086 } 2087 2088 output = &GetSitesOutput{} 2089 req = c.newRequest(op, input, output) 2090 return 2091} 2092 2093// GetSites API operation for AWS Network Manager. 2094// 2095// Gets information about one or more of your sites in a global network. 2096// 2097// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2098// with awserr.Error's Code and Message methods to get detailed information about 2099// the error. 2100// 2101// See the AWS API reference guide for AWS Network Manager's 2102// API operation GetSites for usage and error information. 2103// 2104// Returned Error Types: 2105// * ValidationException 2106// The input fails to satisfy the constraints. 2107// 2108// * AccessDeniedException 2109// You do not have sufficient access to perform this action. 2110// 2111// * ResourceNotFoundException 2112// The specified resource could not be found. 2113// 2114// * ThrottlingException 2115// The request was denied due to request throttling. 2116// 2117// * InternalServerException 2118// The request has failed due to an internal error. 2119// 2120// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/GetSites 2121func (c *NetworkManager) GetSites(input *GetSitesInput) (*GetSitesOutput, error) { 2122 req, out := c.GetSitesRequest(input) 2123 return out, req.Send() 2124} 2125 2126// GetSitesWithContext is the same as GetSites with the addition of 2127// the ability to pass a context and additional request options. 2128// 2129// See GetSites for details on how to use this API operation. 2130// 2131// The context must be non-nil and will be used for request cancellation. If 2132// the context is nil a panic will occur. In the future the SDK may create 2133// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2134// for more information on using Contexts. 2135func (c *NetworkManager) GetSitesWithContext(ctx aws.Context, input *GetSitesInput, opts ...request.Option) (*GetSitesOutput, error) { 2136 req, out := c.GetSitesRequest(input) 2137 req.SetContext(ctx) 2138 req.ApplyOptions(opts...) 2139 return out, req.Send() 2140} 2141 2142// GetSitesPages iterates over the pages of a GetSites operation, 2143// calling the "fn" function with the response data for each page. To stop 2144// iterating, return false from the fn function. 2145// 2146// See GetSites method for more information on how to use this operation. 2147// 2148// Note: This operation can generate multiple requests to a service. 2149// 2150// // Example iterating over at most 3 pages of a GetSites operation. 2151// pageNum := 0 2152// err := client.GetSitesPages(params, 2153// func(page *networkmanager.GetSitesOutput, lastPage bool) bool { 2154// pageNum++ 2155// fmt.Println(page) 2156// return pageNum <= 3 2157// }) 2158// 2159func (c *NetworkManager) GetSitesPages(input *GetSitesInput, fn func(*GetSitesOutput, bool) bool) error { 2160 return c.GetSitesPagesWithContext(aws.BackgroundContext(), input, fn) 2161} 2162 2163// GetSitesPagesWithContext same as GetSitesPages except 2164// it takes a Context and allows setting request options on the pages. 2165// 2166// The context must be non-nil and will be used for request cancellation. If 2167// the context is nil a panic will occur. In the future the SDK may create 2168// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2169// for more information on using Contexts. 2170func (c *NetworkManager) GetSitesPagesWithContext(ctx aws.Context, input *GetSitesInput, fn func(*GetSitesOutput, bool) bool, opts ...request.Option) error { 2171 p := request.Pagination{ 2172 NewRequest: func() (*request.Request, error) { 2173 var inCpy *GetSitesInput 2174 if input != nil { 2175 tmp := *input 2176 inCpy = &tmp 2177 } 2178 req, _ := c.GetSitesRequest(inCpy) 2179 req.SetContext(ctx) 2180 req.ApplyOptions(opts...) 2181 return req, nil 2182 }, 2183 } 2184 2185 for p.Next() { 2186 if !fn(p.Page().(*GetSitesOutput), !p.HasNextPage()) { 2187 break 2188 } 2189 } 2190 2191 return p.Err() 2192} 2193 2194const opGetTransitGatewayRegistrations = "GetTransitGatewayRegistrations" 2195 2196// GetTransitGatewayRegistrationsRequest generates a "aws/request.Request" representing the 2197// client's request for the GetTransitGatewayRegistrations operation. The "output" return 2198// value will be populated with the request's response once the request completes 2199// successfully. 2200// 2201// Use "Send" method on the returned Request to send the API call to the service. 2202// the "output" return value is not valid until after Send returns without error. 2203// 2204// See GetTransitGatewayRegistrations for more information on using the GetTransitGatewayRegistrations 2205// API call, and error handling. 2206// 2207// This method is useful when you want to inject custom logic or configuration 2208// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2209// 2210// 2211// // Example sending a request using the GetTransitGatewayRegistrationsRequest method. 2212// req, resp := client.GetTransitGatewayRegistrationsRequest(params) 2213// 2214// err := req.Send() 2215// if err == nil { // resp is now filled 2216// fmt.Println(resp) 2217// } 2218// 2219// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/GetTransitGatewayRegistrations 2220func (c *NetworkManager) GetTransitGatewayRegistrationsRequest(input *GetTransitGatewayRegistrationsInput) (req *request.Request, output *GetTransitGatewayRegistrationsOutput) { 2221 op := &request.Operation{ 2222 Name: opGetTransitGatewayRegistrations, 2223 HTTPMethod: "GET", 2224 HTTPPath: "/global-networks/{globalNetworkId}/transit-gateway-registrations", 2225 Paginator: &request.Paginator{ 2226 InputTokens: []string{"NextToken"}, 2227 OutputTokens: []string{"NextToken"}, 2228 LimitToken: "MaxResults", 2229 TruncationToken: "", 2230 }, 2231 } 2232 2233 if input == nil { 2234 input = &GetTransitGatewayRegistrationsInput{} 2235 } 2236 2237 output = &GetTransitGatewayRegistrationsOutput{} 2238 req = c.newRequest(op, input, output) 2239 return 2240} 2241 2242// GetTransitGatewayRegistrations API operation for AWS Network Manager. 2243// 2244// Gets information about the transit gateway registrations in a specified global 2245// network. 2246// 2247// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2248// with awserr.Error's Code and Message methods to get detailed information about 2249// the error. 2250// 2251// See the AWS API reference guide for AWS Network Manager's 2252// API operation GetTransitGatewayRegistrations for usage and error information. 2253// 2254// Returned Error Types: 2255// * ValidationException 2256// The input fails to satisfy the constraints. 2257// 2258// * AccessDeniedException 2259// You do not have sufficient access to perform this action. 2260// 2261// * ResourceNotFoundException 2262// The specified resource could not be found. 2263// 2264// * ThrottlingException 2265// The request was denied due to request throttling. 2266// 2267// * InternalServerException 2268// The request has failed due to an internal error. 2269// 2270// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/GetTransitGatewayRegistrations 2271func (c *NetworkManager) GetTransitGatewayRegistrations(input *GetTransitGatewayRegistrationsInput) (*GetTransitGatewayRegistrationsOutput, error) { 2272 req, out := c.GetTransitGatewayRegistrationsRequest(input) 2273 return out, req.Send() 2274} 2275 2276// GetTransitGatewayRegistrationsWithContext is the same as GetTransitGatewayRegistrations with the addition of 2277// the ability to pass a context and additional request options. 2278// 2279// See GetTransitGatewayRegistrations for details on how to use this API operation. 2280// 2281// The context must be non-nil and will be used for request cancellation. If 2282// the context is nil a panic will occur. In the future the SDK may create 2283// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2284// for more information on using Contexts. 2285func (c *NetworkManager) GetTransitGatewayRegistrationsWithContext(ctx aws.Context, input *GetTransitGatewayRegistrationsInput, opts ...request.Option) (*GetTransitGatewayRegistrationsOutput, error) { 2286 req, out := c.GetTransitGatewayRegistrationsRequest(input) 2287 req.SetContext(ctx) 2288 req.ApplyOptions(opts...) 2289 return out, req.Send() 2290} 2291 2292// GetTransitGatewayRegistrationsPages iterates over the pages of a GetTransitGatewayRegistrations operation, 2293// calling the "fn" function with the response data for each page. To stop 2294// iterating, return false from the fn function. 2295// 2296// See GetTransitGatewayRegistrations method for more information on how to use this operation. 2297// 2298// Note: This operation can generate multiple requests to a service. 2299// 2300// // Example iterating over at most 3 pages of a GetTransitGatewayRegistrations operation. 2301// pageNum := 0 2302// err := client.GetTransitGatewayRegistrationsPages(params, 2303// func(page *networkmanager.GetTransitGatewayRegistrationsOutput, lastPage bool) bool { 2304// pageNum++ 2305// fmt.Println(page) 2306// return pageNum <= 3 2307// }) 2308// 2309func (c *NetworkManager) GetTransitGatewayRegistrationsPages(input *GetTransitGatewayRegistrationsInput, fn func(*GetTransitGatewayRegistrationsOutput, bool) bool) error { 2310 return c.GetTransitGatewayRegistrationsPagesWithContext(aws.BackgroundContext(), input, fn) 2311} 2312 2313// GetTransitGatewayRegistrationsPagesWithContext same as GetTransitGatewayRegistrationsPages except 2314// it takes a Context and allows setting request options on the pages. 2315// 2316// The context must be non-nil and will be used for request cancellation. If 2317// the context is nil a panic will occur. In the future the SDK may create 2318// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2319// for more information on using Contexts. 2320func (c *NetworkManager) GetTransitGatewayRegistrationsPagesWithContext(ctx aws.Context, input *GetTransitGatewayRegistrationsInput, fn func(*GetTransitGatewayRegistrationsOutput, bool) bool, opts ...request.Option) error { 2321 p := request.Pagination{ 2322 NewRequest: func() (*request.Request, error) { 2323 var inCpy *GetTransitGatewayRegistrationsInput 2324 if input != nil { 2325 tmp := *input 2326 inCpy = &tmp 2327 } 2328 req, _ := c.GetTransitGatewayRegistrationsRequest(inCpy) 2329 req.SetContext(ctx) 2330 req.ApplyOptions(opts...) 2331 return req, nil 2332 }, 2333 } 2334 2335 for p.Next() { 2336 if !fn(p.Page().(*GetTransitGatewayRegistrationsOutput), !p.HasNextPage()) { 2337 break 2338 } 2339 } 2340 2341 return p.Err() 2342} 2343 2344const opListTagsForResource = "ListTagsForResource" 2345 2346// ListTagsForResourceRequest generates a "aws/request.Request" representing the 2347// client's request for the ListTagsForResource operation. The "output" return 2348// value will be populated with the request's response once the request completes 2349// successfully. 2350// 2351// Use "Send" method on the returned Request to send the API call to the service. 2352// the "output" return value is not valid until after Send returns without error. 2353// 2354// See ListTagsForResource for more information on using the ListTagsForResource 2355// API call, and error handling. 2356// 2357// This method is useful when you want to inject custom logic or configuration 2358// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2359// 2360// 2361// // Example sending a request using the ListTagsForResourceRequest method. 2362// req, resp := client.ListTagsForResourceRequest(params) 2363// 2364// err := req.Send() 2365// if err == nil { // resp is now filled 2366// fmt.Println(resp) 2367// } 2368// 2369// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/ListTagsForResource 2370func (c *NetworkManager) ListTagsForResourceRequest(input *ListTagsForResourceInput) (req *request.Request, output *ListTagsForResourceOutput) { 2371 op := &request.Operation{ 2372 Name: opListTagsForResource, 2373 HTTPMethod: "GET", 2374 HTTPPath: "/tags/{resourceArn}", 2375 } 2376 2377 if input == nil { 2378 input = &ListTagsForResourceInput{} 2379 } 2380 2381 output = &ListTagsForResourceOutput{} 2382 req = c.newRequest(op, input, output) 2383 return 2384} 2385 2386// ListTagsForResource API operation for AWS Network Manager. 2387// 2388// Lists the tags for a specified resource. 2389// 2390// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2391// with awserr.Error's Code and Message methods to get detailed information about 2392// the error. 2393// 2394// See the AWS API reference guide for AWS Network Manager's 2395// API operation ListTagsForResource for usage and error information. 2396// 2397// Returned Error Types: 2398// * ValidationException 2399// The input fails to satisfy the constraints. 2400// 2401// * AccessDeniedException 2402// You do not have sufficient access to perform this action. 2403// 2404// * ResourceNotFoundException 2405// The specified resource could not be found. 2406// 2407// * ThrottlingException 2408// The request was denied due to request throttling. 2409// 2410// * InternalServerException 2411// The request has failed due to an internal error. 2412// 2413// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/ListTagsForResource 2414func (c *NetworkManager) ListTagsForResource(input *ListTagsForResourceInput) (*ListTagsForResourceOutput, error) { 2415 req, out := c.ListTagsForResourceRequest(input) 2416 return out, req.Send() 2417} 2418 2419// ListTagsForResourceWithContext is the same as ListTagsForResource with the addition of 2420// the ability to pass a context and additional request options. 2421// 2422// See ListTagsForResource for details on how to use this API operation. 2423// 2424// The context must be non-nil and will be used for request cancellation. If 2425// the context is nil a panic will occur. In the future the SDK may create 2426// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2427// for more information on using Contexts. 2428func (c *NetworkManager) ListTagsForResourceWithContext(ctx aws.Context, input *ListTagsForResourceInput, opts ...request.Option) (*ListTagsForResourceOutput, error) { 2429 req, out := c.ListTagsForResourceRequest(input) 2430 req.SetContext(ctx) 2431 req.ApplyOptions(opts...) 2432 return out, req.Send() 2433} 2434 2435const opRegisterTransitGateway = "RegisterTransitGateway" 2436 2437// RegisterTransitGatewayRequest generates a "aws/request.Request" representing the 2438// client's request for the RegisterTransitGateway operation. The "output" return 2439// value will be populated with the request's response once the request completes 2440// successfully. 2441// 2442// Use "Send" method on the returned Request to send the API call to the service. 2443// the "output" return value is not valid until after Send returns without error. 2444// 2445// See RegisterTransitGateway for more information on using the RegisterTransitGateway 2446// API call, and error handling. 2447// 2448// This method is useful when you want to inject custom logic or configuration 2449// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2450// 2451// 2452// // Example sending a request using the RegisterTransitGatewayRequest method. 2453// req, resp := client.RegisterTransitGatewayRequest(params) 2454// 2455// err := req.Send() 2456// if err == nil { // resp is now filled 2457// fmt.Println(resp) 2458// } 2459// 2460// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/RegisterTransitGateway 2461func (c *NetworkManager) RegisterTransitGatewayRequest(input *RegisterTransitGatewayInput) (req *request.Request, output *RegisterTransitGatewayOutput) { 2462 op := &request.Operation{ 2463 Name: opRegisterTransitGateway, 2464 HTTPMethod: "POST", 2465 HTTPPath: "/global-networks/{globalNetworkId}/transit-gateway-registrations", 2466 } 2467 2468 if input == nil { 2469 input = &RegisterTransitGatewayInput{} 2470 } 2471 2472 output = &RegisterTransitGatewayOutput{} 2473 req = c.newRequest(op, input, output) 2474 return 2475} 2476 2477// RegisterTransitGateway API operation for AWS Network Manager. 2478// 2479// Registers a transit gateway in your global network. The transit gateway can 2480// be in any AWS Region, but it must be owned by the same AWS account that owns 2481// the global network. You cannot register a transit gateway in more than one 2482// global network. 2483// 2484// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2485// with awserr.Error's Code and Message methods to get detailed information about 2486// the error. 2487// 2488// See the AWS API reference guide for AWS Network Manager's 2489// API operation RegisterTransitGateway for usage and error information. 2490// 2491// Returned Error Types: 2492// * ValidationException 2493// The input fails to satisfy the constraints. 2494// 2495// * AccessDeniedException 2496// You do not have sufficient access to perform this action. 2497// 2498// * ResourceNotFoundException 2499// The specified resource could not be found. 2500// 2501// * ConflictException 2502// There was a conflict processing the request. Updating or deleting the resource 2503// can cause an inconsistent state. 2504// 2505// * ThrottlingException 2506// The request was denied due to request throttling. 2507// 2508// * InternalServerException 2509// The request has failed due to an internal error. 2510// 2511// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/RegisterTransitGateway 2512func (c *NetworkManager) RegisterTransitGateway(input *RegisterTransitGatewayInput) (*RegisterTransitGatewayOutput, error) { 2513 req, out := c.RegisterTransitGatewayRequest(input) 2514 return out, req.Send() 2515} 2516 2517// RegisterTransitGatewayWithContext is the same as RegisterTransitGateway with the addition of 2518// the ability to pass a context and additional request options. 2519// 2520// See RegisterTransitGateway for details on how to use this API operation. 2521// 2522// The context must be non-nil and will be used for request cancellation. If 2523// the context is nil a panic will occur. In the future the SDK may create 2524// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2525// for more information on using Contexts. 2526func (c *NetworkManager) RegisterTransitGatewayWithContext(ctx aws.Context, input *RegisterTransitGatewayInput, opts ...request.Option) (*RegisterTransitGatewayOutput, error) { 2527 req, out := c.RegisterTransitGatewayRequest(input) 2528 req.SetContext(ctx) 2529 req.ApplyOptions(opts...) 2530 return out, req.Send() 2531} 2532 2533const opTagResource = "TagResource" 2534 2535// TagResourceRequest generates a "aws/request.Request" representing the 2536// client's request for the TagResource operation. The "output" return 2537// value will be populated with the request's response once the request completes 2538// successfully. 2539// 2540// Use "Send" method on the returned Request to send the API call to the service. 2541// the "output" return value is not valid until after Send returns without error. 2542// 2543// See TagResource for more information on using the TagResource 2544// API call, and error handling. 2545// 2546// This method is useful when you want to inject custom logic or configuration 2547// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2548// 2549// 2550// // Example sending a request using the TagResourceRequest method. 2551// req, resp := client.TagResourceRequest(params) 2552// 2553// err := req.Send() 2554// if err == nil { // resp is now filled 2555// fmt.Println(resp) 2556// } 2557// 2558// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/TagResource 2559func (c *NetworkManager) TagResourceRequest(input *TagResourceInput) (req *request.Request, output *TagResourceOutput) { 2560 op := &request.Operation{ 2561 Name: opTagResource, 2562 HTTPMethod: "POST", 2563 HTTPPath: "/tags/{resourceArn}", 2564 } 2565 2566 if input == nil { 2567 input = &TagResourceInput{} 2568 } 2569 2570 output = &TagResourceOutput{} 2571 req = c.newRequest(op, input, output) 2572 req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 2573 return 2574} 2575 2576// TagResource API operation for AWS Network Manager. 2577// 2578// Tags a specified resource. 2579// 2580// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2581// with awserr.Error's Code and Message methods to get detailed information about 2582// the error. 2583// 2584// See the AWS API reference guide for AWS Network Manager's 2585// API operation TagResource for usage and error information. 2586// 2587// Returned Error Types: 2588// * ValidationException 2589// The input fails to satisfy the constraints. 2590// 2591// * ServiceQuotaExceededException 2592// A service limit was exceeded. 2593// 2594// * AccessDeniedException 2595// You do not have sufficient access to perform this action. 2596// 2597// * ResourceNotFoundException 2598// The specified resource could not be found. 2599// 2600// * ConflictException 2601// There was a conflict processing the request. Updating or deleting the resource 2602// can cause an inconsistent state. 2603// 2604// * ThrottlingException 2605// The request was denied due to request throttling. 2606// 2607// * InternalServerException 2608// The request has failed due to an internal error. 2609// 2610// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/TagResource 2611func (c *NetworkManager) TagResource(input *TagResourceInput) (*TagResourceOutput, error) { 2612 req, out := c.TagResourceRequest(input) 2613 return out, req.Send() 2614} 2615 2616// TagResourceWithContext is the same as TagResource with the addition of 2617// the ability to pass a context and additional request options. 2618// 2619// See TagResource for details on how to use this API operation. 2620// 2621// The context must be non-nil and will be used for request cancellation. If 2622// the context is nil a panic will occur. In the future the SDK may create 2623// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2624// for more information on using Contexts. 2625func (c *NetworkManager) TagResourceWithContext(ctx aws.Context, input *TagResourceInput, opts ...request.Option) (*TagResourceOutput, error) { 2626 req, out := c.TagResourceRequest(input) 2627 req.SetContext(ctx) 2628 req.ApplyOptions(opts...) 2629 return out, req.Send() 2630} 2631 2632const opUntagResource = "UntagResource" 2633 2634// UntagResourceRequest generates a "aws/request.Request" representing the 2635// client's request for the UntagResource operation. The "output" return 2636// value will be populated with the request's response once the request completes 2637// successfully. 2638// 2639// Use "Send" method on the returned Request to send the API call to the service. 2640// the "output" return value is not valid until after Send returns without error. 2641// 2642// See UntagResource for more information on using the UntagResource 2643// API call, and error handling. 2644// 2645// This method is useful when you want to inject custom logic or configuration 2646// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2647// 2648// 2649// // Example sending a request using the UntagResourceRequest method. 2650// req, resp := client.UntagResourceRequest(params) 2651// 2652// err := req.Send() 2653// if err == nil { // resp is now filled 2654// fmt.Println(resp) 2655// } 2656// 2657// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/UntagResource 2658func (c *NetworkManager) UntagResourceRequest(input *UntagResourceInput) (req *request.Request, output *UntagResourceOutput) { 2659 op := &request.Operation{ 2660 Name: opUntagResource, 2661 HTTPMethod: "DELETE", 2662 HTTPPath: "/tags/{resourceArn}", 2663 } 2664 2665 if input == nil { 2666 input = &UntagResourceInput{} 2667 } 2668 2669 output = &UntagResourceOutput{} 2670 req = c.newRequest(op, input, output) 2671 req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 2672 return 2673} 2674 2675// UntagResource API operation for AWS Network Manager. 2676// 2677// Removes tags from a specified resource. 2678// 2679// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2680// with awserr.Error's Code and Message methods to get detailed information about 2681// the error. 2682// 2683// See the AWS API reference guide for AWS Network Manager's 2684// API operation UntagResource for usage and error information. 2685// 2686// Returned Error Types: 2687// * ValidationException 2688// The input fails to satisfy the constraints. 2689// 2690// * AccessDeniedException 2691// You do not have sufficient access to perform this action. 2692// 2693// * ResourceNotFoundException 2694// The specified resource could not be found. 2695// 2696// * ConflictException 2697// There was a conflict processing the request. Updating or deleting the resource 2698// can cause an inconsistent state. 2699// 2700// * ThrottlingException 2701// The request was denied due to request throttling. 2702// 2703// * InternalServerException 2704// The request has failed due to an internal error. 2705// 2706// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/UntagResource 2707func (c *NetworkManager) UntagResource(input *UntagResourceInput) (*UntagResourceOutput, error) { 2708 req, out := c.UntagResourceRequest(input) 2709 return out, req.Send() 2710} 2711 2712// UntagResourceWithContext is the same as UntagResource with the addition of 2713// the ability to pass a context and additional request options. 2714// 2715// See UntagResource for details on how to use this API operation. 2716// 2717// The context must be non-nil and will be used for request cancellation. If 2718// the context is nil a panic will occur. In the future the SDK may create 2719// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2720// for more information on using Contexts. 2721func (c *NetworkManager) UntagResourceWithContext(ctx aws.Context, input *UntagResourceInput, opts ...request.Option) (*UntagResourceOutput, error) { 2722 req, out := c.UntagResourceRequest(input) 2723 req.SetContext(ctx) 2724 req.ApplyOptions(opts...) 2725 return out, req.Send() 2726} 2727 2728const opUpdateDevice = "UpdateDevice" 2729 2730// UpdateDeviceRequest generates a "aws/request.Request" representing the 2731// client's request for the UpdateDevice operation. The "output" return 2732// value will be populated with the request's response once the request completes 2733// successfully. 2734// 2735// Use "Send" method on the returned Request to send the API call to the service. 2736// the "output" return value is not valid until after Send returns without error. 2737// 2738// See UpdateDevice for more information on using the UpdateDevice 2739// API call, and error handling. 2740// 2741// This method is useful when you want to inject custom logic or configuration 2742// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2743// 2744// 2745// // Example sending a request using the UpdateDeviceRequest method. 2746// req, resp := client.UpdateDeviceRequest(params) 2747// 2748// err := req.Send() 2749// if err == nil { // resp is now filled 2750// fmt.Println(resp) 2751// } 2752// 2753// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/UpdateDevice 2754func (c *NetworkManager) UpdateDeviceRequest(input *UpdateDeviceInput) (req *request.Request, output *UpdateDeviceOutput) { 2755 op := &request.Operation{ 2756 Name: opUpdateDevice, 2757 HTTPMethod: "PATCH", 2758 HTTPPath: "/global-networks/{globalNetworkId}/devices/{deviceId}", 2759 } 2760 2761 if input == nil { 2762 input = &UpdateDeviceInput{} 2763 } 2764 2765 output = &UpdateDeviceOutput{} 2766 req = c.newRequest(op, input, output) 2767 return 2768} 2769 2770// UpdateDevice API operation for AWS Network Manager. 2771// 2772// Updates the details for an existing device. To remove information for any 2773// of the parameters, specify an empty string. 2774// 2775// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2776// with awserr.Error's Code and Message methods to get detailed information about 2777// the error. 2778// 2779// See the AWS API reference guide for AWS Network Manager's 2780// API operation UpdateDevice for usage and error information. 2781// 2782// Returned Error Types: 2783// * ValidationException 2784// The input fails to satisfy the constraints. 2785// 2786// * AccessDeniedException 2787// You do not have sufficient access to perform this action. 2788// 2789// * ResourceNotFoundException 2790// The specified resource could not be found. 2791// 2792// * ConflictException 2793// There was a conflict processing the request. Updating or deleting the resource 2794// can cause an inconsistent state. 2795// 2796// * ThrottlingException 2797// The request was denied due to request throttling. 2798// 2799// * InternalServerException 2800// The request has failed due to an internal error. 2801// 2802// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/UpdateDevice 2803func (c *NetworkManager) UpdateDevice(input *UpdateDeviceInput) (*UpdateDeviceOutput, error) { 2804 req, out := c.UpdateDeviceRequest(input) 2805 return out, req.Send() 2806} 2807 2808// UpdateDeviceWithContext is the same as UpdateDevice with the addition of 2809// the ability to pass a context and additional request options. 2810// 2811// See UpdateDevice for details on how to use this API operation. 2812// 2813// The context must be non-nil and will be used for request cancellation. If 2814// the context is nil a panic will occur. In the future the SDK may create 2815// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2816// for more information on using Contexts. 2817func (c *NetworkManager) UpdateDeviceWithContext(ctx aws.Context, input *UpdateDeviceInput, opts ...request.Option) (*UpdateDeviceOutput, error) { 2818 req, out := c.UpdateDeviceRequest(input) 2819 req.SetContext(ctx) 2820 req.ApplyOptions(opts...) 2821 return out, req.Send() 2822} 2823 2824const opUpdateGlobalNetwork = "UpdateGlobalNetwork" 2825 2826// UpdateGlobalNetworkRequest generates a "aws/request.Request" representing the 2827// client's request for the UpdateGlobalNetwork operation. The "output" return 2828// value will be populated with the request's response once the request completes 2829// successfully. 2830// 2831// Use "Send" method on the returned Request to send the API call to the service. 2832// the "output" return value is not valid until after Send returns without error. 2833// 2834// See UpdateGlobalNetwork for more information on using the UpdateGlobalNetwork 2835// API call, and error handling. 2836// 2837// This method is useful when you want to inject custom logic or configuration 2838// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2839// 2840// 2841// // Example sending a request using the UpdateGlobalNetworkRequest method. 2842// req, resp := client.UpdateGlobalNetworkRequest(params) 2843// 2844// err := req.Send() 2845// if err == nil { // resp is now filled 2846// fmt.Println(resp) 2847// } 2848// 2849// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/UpdateGlobalNetwork 2850func (c *NetworkManager) UpdateGlobalNetworkRequest(input *UpdateGlobalNetworkInput) (req *request.Request, output *UpdateGlobalNetworkOutput) { 2851 op := &request.Operation{ 2852 Name: opUpdateGlobalNetwork, 2853 HTTPMethod: "PATCH", 2854 HTTPPath: "/global-networks/{globalNetworkId}", 2855 } 2856 2857 if input == nil { 2858 input = &UpdateGlobalNetworkInput{} 2859 } 2860 2861 output = &UpdateGlobalNetworkOutput{} 2862 req = c.newRequest(op, input, output) 2863 return 2864} 2865 2866// UpdateGlobalNetwork API operation for AWS Network Manager. 2867// 2868// Updates an existing global network. To remove information for any of the 2869// parameters, specify an empty string. 2870// 2871// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2872// with awserr.Error's Code and Message methods to get detailed information about 2873// the error. 2874// 2875// See the AWS API reference guide for AWS Network Manager's 2876// API operation UpdateGlobalNetwork for usage and error information. 2877// 2878// Returned Error Types: 2879// * ValidationException 2880// The input fails to satisfy the constraints. 2881// 2882// * AccessDeniedException 2883// You do not have sufficient access to perform this action. 2884// 2885// * ResourceNotFoundException 2886// The specified resource could not be found. 2887// 2888// * ConflictException 2889// There was a conflict processing the request. Updating or deleting the resource 2890// can cause an inconsistent state. 2891// 2892// * ThrottlingException 2893// The request was denied due to request throttling. 2894// 2895// * InternalServerException 2896// The request has failed due to an internal error. 2897// 2898// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/UpdateGlobalNetwork 2899func (c *NetworkManager) UpdateGlobalNetwork(input *UpdateGlobalNetworkInput) (*UpdateGlobalNetworkOutput, error) { 2900 req, out := c.UpdateGlobalNetworkRequest(input) 2901 return out, req.Send() 2902} 2903 2904// UpdateGlobalNetworkWithContext is the same as UpdateGlobalNetwork with the addition of 2905// the ability to pass a context and additional request options. 2906// 2907// See UpdateGlobalNetwork for details on how to use this API operation. 2908// 2909// The context must be non-nil and will be used for request cancellation. If 2910// the context is nil a panic will occur. In the future the SDK may create 2911// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2912// for more information on using Contexts. 2913func (c *NetworkManager) UpdateGlobalNetworkWithContext(ctx aws.Context, input *UpdateGlobalNetworkInput, opts ...request.Option) (*UpdateGlobalNetworkOutput, error) { 2914 req, out := c.UpdateGlobalNetworkRequest(input) 2915 req.SetContext(ctx) 2916 req.ApplyOptions(opts...) 2917 return out, req.Send() 2918} 2919 2920const opUpdateLink = "UpdateLink" 2921 2922// UpdateLinkRequest generates a "aws/request.Request" representing the 2923// client's request for the UpdateLink operation. The "output" return 2924// value will be populated with the request's response once the request completes 2925// successfully. 2926// 2927// Use "Send" method on the returned Request to send the API call to the service. 2928// the "output" return value is not valid until after Send returns without error. 2929// 2930// See UpdateLink for more information on using the UpdateLink 2931// API call, and error handling. 2932// 2933// This method is useful when you want to inject custom logic or configuration 2934// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2935// 2936// 2937// // Example sending a request using the UpdateLinkRequest method. 2938// req, resp := client.UpdateLinkRequest(params) 2939// 2940// err := req.Send() 2941// if err == nil { // resp is now filled 2942// fmt.Println(resp) 2943// } 2944// 2945// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/UpdateLink 2946func (c *NetworkManager) UpdateLinkRequest(input *UpdateLinkInput) (req *request.Request, output *UpdateLinkOutput) { 2947 op := &request.Operation{ 2948 Name: opUpdateLink, 2949 HTTPMethod: "PATCH", 2950 HTTPPath: "/global-networks/{globalNetworkId}/links/{linkId}", 2951 } 2952 2953 if input == nil { 2954 input = &UpdateLinkInput{} 2955 } 2956 2957 output = &UpdateLinkOutput{} 2958 req = c.newRequest(op, input, output) 2959 return 2960} 2961 2962// UpdateLink API operation for AWS Network Manager. 2963// 2964// Updates the details for an existing link. To remove information for any of 2965// the parameters, specify an empty string. 2966// 2967// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2968// with awserr.Error's Code and Message methods to get detailed information about 2969// the error. 2970// 2971// See the AWS API reference guide for AWS Network Manager's 2972// API operation UpdateLink for usage and error information. 2973// 2974// Returned Error Types: 2975// * ValidationException 2976// The input fails to satisfy the constraints. 2977// 2978// * ServiceQuotaExceededException 2979// A service limit was exceeded. 2980// 2981// * AccessDeniedException 2982// You do not have sufficient access to perform this action. 2983// 2984// * ResourceNotFoundException 2985// The specified resource could not be found. 2986// 2987// * ConflictException 2988// There was a conflict processing the request. Updating or deleting the resource 2989// can cause an inconsistent state. 2990// 2991// * ThrottlingException 2992// The request was denied due to request throttling. 2993// 2994// * InternalServerException 2995// The request has failed due to an internal error. 2996// 2997// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/UpdateLink 2998func (c *NetworkManager) UpdateLink(input *UpdateLinkInput) (*UpdateLinkOutput, error) { 2999 req, out := c.UpdateLinkRequest(input) 3000 return out, req.Send() 3001} 3002 3003// UpdateLinkWithContext is the same as UpdateLink with the addition of 3004// the ability to pass a context and additional request options. 3005// 3006// See UpdateLink for details on how to use this API operation. 3007// 3008// The context must be non-nil and will be used for request cancellation. If 3009// the context is nil a panic will occur. In the future the SDK may create 3010// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 3011// for more information on using Contexts. 3012func (c *NetworkManager) UpdateLinkWithContext(ctx aws.Context, input *UpdateLinkInput, opts ...request.Option) (*UpdateLinkOutput, error) { 3013 req, out := c.UpdateLinkRequest(input) 3014 req.SetContext(ctx) 3015 req.ApplyOptions(opts...) 3016 return out, req.Send() 3017} 3018 3019const opUpdateSite = "UpdateSite" 3020 3021// UpdateSiteRequest generates a "aws/request.Request" representing the 3022// client's request for the UpdateSite operation. The "output" return 3023// value will be populated with the request's response once the request completes 3024// successfully. 3025// 3026// Use "Send" method on the returned Request to send the API call to the service. 3027// the "output" return value is not valid until after Send returns without error. 3028// 3029// See UpdateSite for more information on using the UpdateSite 3030// API call, and error handling. 3031// 3032// This method is useful when you want to inject custom logic or configuration 3033// into the SDK's request lifecycle. Such as custom headers, or retry logic. 3034// 3035// 3036// // Example sending a request using the UpdateSiteRequest method. 3037// req, resp := client.UpdateSiteRequest(params) 3038// 3039// err := req.Send() 3040// if err == nil { // resp is now filled 3041// fmt.Println(resp) 3042// } 3043// 3044// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/UpdateSite 3045func (c *NetworkManager) UpdateSiteRequest(input *UpdateSiteInput) (req *request.Request, output *UpdateSiteOutput) { 3046 op := &request.Operation{ 3047 Name: opUpdateSite, 3048 HTTPMethod: "PATCH", 3049 HTTPPath: "/global-networks/{globalNetworkId}/sites/{siteId}", 3050 } 3051 3052 if input == nil { 3053 input = &UpdateSiteInput{} 3054 } 3055 3056 output = &UpdateSiteOutput{} 3057 req = c.newRequest(op, input, output) 3058 return 3059} 3060 3061// UpdateSite API operation for AWS Network Manager. 3062// 3063// Updates the information for an existing site. To remove information for any 3064// of the parameters, specify an empty string. 3065// 3066// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 3067// with awserr.Error's Code and Message methods to get detailed information about 3068// the error. 3069// 3070// See the AWS API reference guide for AWS Network Manager's 3071// API operation UpdateSite for usage and error information. 3072// 3073// Returned Error Types: 3074// * ValidationException 3075// The input fails to satisfy the constraints. 3076// 3077// * AccessDeniedException 3078// You do not have sufficient access to perform this action. 3079// 3080// * ResourceNotFoundException 3081// The specified resource could not be found. 3082// 3083// * ConflictException 3084// There was a conflict processing the request. Updating or deleting the resource 3085// can cause an inconsistent state. 3086// 3087// * ThrottlingException 3088// The request was denied due to request throttling. 3089// 3090// * InternalServerException 3091// The request has failed due to an internal error. 3092// 3093// See also, https://docs.aws.amazon.com/goto/WebAPI/networkmanager-2019-07-05/UpdateSite 3094func (c *NetworkManager) UpdateSite(input *UpdateSiteInput) (*UpdateSiteOutput, error) { 3095 req, out := c.UpdateSiteRequest(input) 3096 return out, req.Send() 3097} 3098 3099// UpdateSiteWithContext is the same as UpdateSite with the addition of 3100// the ability to pass a context and additional request options. 3101// 3102// See UpdateSite for details on how to use this API operation. 3103// 3104// The context must be non-nil and will be used for request cancellation. If 3105// the context is nil a panic will occur. In the future the SDK may create 3106// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 3107// for more information on using Contexts. 3108func (c *NetworkManager) UpdateSiteWithContext(ctx aws.Context, input *UpdateSiteInput, opts ...request.Option) (*UpdateSiteOutput, error) { 3109 req, out := c.UpdateSiteRequest(input) 3110 req.SetContext(ctx) 3111 req.ApplyOptions(opts...) 3112 return out, req.Send() 3113} 3114 3115// You do not have sufficient access to perform this action. 3116type AccessDeniedException struct { 3117 _ struct{} `type:"structure"` 3118 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 3119 3120 Message_ *string `locationName:"Message" type:"string"` 3121} 3122 3123// String returns the string representation 3124func (s AccessDeniedException) String() string { 3125 return awsutil.Prettify(s) 3126} 3127 3128// GoString returns the string representation 3129func (s AccessDeniedException) GoString() string { 3130 return s.String() 3131} 3132 3133func newErrorAccessDeniedException(v protocol.ResponseMetadata) error { 3134 return &AccessDeniedException{ 3135 RespMetadata: v, 3136 } 3137} 3138 3139// Code returns the exception type name. 3140func (s *AccessDeniedException) Code() string { 3141 return "AccessDeniedException" 3142} 3143 3144// Message returns the exception's message. 3145func (s *AccessDeniedException) Message() string { 3146 if s.Message_ != nil { 3147 return *s.Message_ 3148 } 3149 return "" 3150} 3151 3152// OrigErr always returns nil, satisfies awserr.Error interface. 3153func (s *AccessDeniedException) OrigErr() error { 3154 return nil 3155} 3156 3157func (s *AccessDeniedException) Error() string { 3158 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 3159} 3160 3161// Status code returns the HTTP status code for the request's response error. 3162func (s *AccessDeniedException) StatusCode() int { 3163 return s.RespMetadata.StatusCode 3164} 3165 3166// RequestID returns the service's response RequestID for request. 3167func (s *AccessDeniedException) RequestID() string { 3168 return s.RespMetadata.RequestID 3169} 3170 3171type AssociateCustomerGatewayInput struct { 3172 _ struct{} `type:"structure"` 3173 3174 // The Amazon Resource Name (ARN) of the customer gateway. For more information, 3175 // see Resources Defined by Amazon EC2 (https://docs.aws.amazon.com/IAM/latest/UserGuide/list_amazonec2.html#amazonec2-resources-for-iam-policies). 3176 // 3177 // CustomerGatewayArn is a required field 3178 CustomerGatewayArn *string `type:"string" required:"true"` 3179 3180 // The ID of the device. 3181 // 3182 // DeviceId is a required field 3183 DeviceId *string `type:"string" required:"true"` 3184 3185 // The ID of the global network. 3186 // 3187 // GlobalNetworkId is a required field 3188 GlobalNetworkId *string `location:"uri" locationName:"globalNetworkId" type:"string" required:"true"` 3189 3190 // The ID of the link. 3191 LinkId *string `type:"string"` 3192} 3193 3194// String returns the string representation 3195func (s AssociateCustomerGatewayInput) String() string { 3196 return awsutil.Prettify(s) 3197} 3198 3199// GoString returns the string representation 3200func (s AssociateCustomerGatewayInput) GoString() string { 3201 return s.String() 3202} 3203 3204// Validate inspects the fields of the type to determine if they are valid. 3205func (s *AssociateCustomerGatewayInput) Validate() error { 3206 invalidParams := request.ErrInvalidParams{Context: "AssociateCustomerGatewayInput"} 3207 if s.CustomerGatewayArn == nil { 3208 invalidParams.Add(request.NewErrParamRequired("CustomerGatewayArn")) 3209 } 3210 if s.DeviceId == nil { 3211 invalidParams.Add(request.NewErrParamRequired("DeviceId")) 3212 } 3213 if s.GlobalNetworkId == nil { 3214 invalidParams.Add(request.NewErrParamRequired("GlobalNetworkId")) 3215 } 3216 if s.GlobalNetworkId != nil && len(*s.GlobalNetworkId) < 1 { 3217 invalidParams.Add(request.NewErrParamMinLen("GlobalNetworkId", 1)) 3218 } 3219 3220 if invalidParams.Len() > 0 { 3221 return invalidParams 3222 } 3223 return nil 3224} 3225 3226// SetCustomerGatewayArn sets the CustomerGatewayArn field's value. 3227func (s *AssociateCustomerGatewayInput) SetCustomerGatewayArn(v string) *AssociateCustomerGatewayInput { 3228 s.CustomerGatewayArn = &v 3229 return s 3230} 3231 3232// SetDeviceId sets the DeviceId field's value. 3233func (s *AssociateCustomerGatewayInput) SetDeviceId(v string) *AssociateCustomerGatewayInput { 3234 s.DeviceId = &v 3235 return s 3236} 3237 3238// SetGlobalNetworkId sets the GlobalNetworkId field's value. 3239func (s *AssociateCustomerGatewayInput) SetGlobalNetworkId(v string) *AssociateCustomerGatewayInput { 3240 s.GlobalNetworkId = &v 3241 return s 3242} 3243 3244// SetLinkId sets the LinkId field's value. 3245func (s *AssociateCustomerGatewayInput) SetLinkId(v string) *AssociateCustomerGatewayInput { 3246 s.LinkId = &v 3247 return s 3248} 3249 3250type AssociateCustomerGatewayOutput struct { 3251 _ struct{} `type:"structure"` 3252 3253 // The customer gateway association. 3254 CustomerGatewayAssociation *CustomerGatewayAssociation `type:"structure"` 3255} 3256 3257// String returns the string representation 3258func (s AssociateCustomerGatewayOutput) String() string { 3259 return awsutil.Prettify(s) 3260} 3261 3262// GoString returns the string representation 3263func (s AssociateCustomerGatewayOutput) GoString() string { 3264 return s.String() 3265} 3266 3267// SetCustomerGatewayAssociation sets the CustomerGatewayAssociation field's value. 3268func (s *AssociateCustomerGatewayOutput) SetCustomerGatewayAssociation(v *CustomerGatewayAssociation) *AssociateCustomerGatewayOutput { 3269 s.CustomerGatewayAssociation = v 3270 return s 3271} 3272 3273type AssociateLinkInput struct { 3274 _ struct{} `type:"structure"` 3275 3276 // The ID of the device. 3277 // 3278 // DeviceId is a required field 3279 DeviceId *string `type:"string" required:"true"` 3280 3281 // The ID of the global network. 3282 // 3283 // GlobalNetworkId is a required field 3284 GlobalNetworkId *string `location:"uri" locationName:"globalNetworkId" type:"string" required:"true"` 3285 3286 // The ID of the link. 3287 // 3288 // LinkId is a required field 3289 LinkId *string `type:"string" required:"true"` 3290} 3291 3292// String returns the string representation 3293func (s AssociateLinkInput) String() string { 3294 return awsutil.Prettify(s) 3295} 3296 3297// GoString returns the string representation 3298func (s AssociateLinkInput) GoString() string { 3299 return s.String() 3300} 3301 3302// Validate inspects the fields of the type to determine if they are valid. 3303func (s *AssociateLinkInput) Validate() error { 3304 invalidParams := request.ErrInvalidParams{Context: "AssociateLinkInput"} 3305 if s.DeviceId == nil { 3306 invalidParams.Add(request.NewErrParamRequired("DeviceId")) 3307 } 3308 if s.GlobalNetworkId == nil { 3309 invalidParams.Add(request.NewErrParamRequired("GlobalNetworkId")) 3310 } 3311 if s.GlobalNetworkId != nil && len(*s.GlobalNetworkId) < 1 { 3312 invalidParams.Add(request.NewErrParamMinLen("GlobalNetworkId", 1)) 3313 } 3314 if s.LinkId == nil { 3315 invalidParams.Add(request.NewErrParamRequired("LinkId")) 3316 } 3317 3318 if invalidParams.Len() > 0 { 3319 return invalidParams 3320 } 3321 return nil 3322} 3323 3324// SetDeviceId sets the DeviceId field's value. 3325func (s *AssociateLinkInput) SetDeviceId(v string) *AssociateLinkInput { 3326 s.DeviceId = &v 3327 return s 3328} 3329 3330// SetGlobalNetworkId sets the GlobalNetworkId field's value. 3331func (s *AssociateLinkInput) SetGlobalNetworkId(v string) *AssociateLinkInput { 3332 s.GlobalNetworkId = &v 3333 return s 3334} 3335 3336// SetLinkId sets the LinkId field's value. 3337func (s *AssociateLinkInput) SetLinkId(v string) *AssociateLinkInput { 3338 s.LinkId = &v 3339 return s 3340} 3341 3342type AssociateLinkOutput struct { 3343 _ struct{} `type:"structure"` 3344 3345 // The link association. 3346 LinkAssociation *LinkAssociation `type:"structure"` 3347} 3348 3349// String returns the string representation 3350func (s AssociateLinkOutput) String() string { 3351 return awsutil.Prettify(s) 3352} 3353 3354// GoString returns the string representation 3355func (s AssociateLinkOutput) GoString() string { 3356 return s.String() 3357} 3358 3359// SetLinkAssociation sets the LinkAssociation field's value. 3360func (s *AssociateLinkOutput) SetLinkAssociation(v *LinkAssociation) *AssociateLinkOutput { 3361 s.LinkAssociation = v 3362 return s 3363} 3364 3365// Describes bandwidth information. 3366type Bandwidth struct { 3367 _ struct{} `type:"structure"` 3368 3369 // Download speed in Mbps. 3370 DownloadSpeed *int64 `type:"integer"` 3371 3372 // Upload speed in Mbps. 3373 UploadSpeed *int64 `type:"integer"` 3374} 3375 3376// String returns the string representation 3377func (s Bandwidth) String() string { 3378 return awsutil.Prettify(s) 3379} 3380 3381// GoString returns the string representation 3382func (s Bandwidth) GoString() string { 3383 return s.String() 3384} 3385 3386// SetDownloadSpeed sets the DownloadSpeed field's value. 3387func (s *Bandwidth) SetDownloadSpeed(v int64) *Bandwidth { 3388 s.DownloadSpeed = &v 3389 return s 3390} 3391 3392// SetUploadSpeed sets the UploadSpeed field's value. 3393func (s *Bandwidth) SetUploadSpeed(v int64) *Bandwidth { 3394 s.UploadSpeed = &v 3395 return s 3396} 3397 3398// There was a conflict processing the request. Updating or deleting the resource 3399// can cause an inconsistent state. 3400type ConflictException struct { 3401 _ struct{} `type:"structure"` 3402 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 3403 3404 Message_ *string `locationName:"Message" type:"string"` 3405 3406 // The ID of the resource. 3407 // 3408 // ResourceId is a required field 3409 ResourceId *string `type:"string" required:"true"` 3410 3411 // The resource type. 3412 // 3413 // ResourceType is a required field 3414 ResourceType *string `type:"string" required:"true"` 3415} 3416 3417// String returns the string representation 3418func (s ConflictException) String() string { 3419 return awsutil.Prettify(s) 3420} 3421 3422// GoString returns the string representation 3423func (s ConflictException) GoString() string { 3424 return s.String() 3425} 3426 3427func newErrorConflictException(v protocol.ResponseMetadata) error { 3428 return &ConflictException{ 3429 RespMetadata: v, 3430 } 3431} 3432 3433// Code returns the exception type name. 3434func (s *ConflictException) Code() string { 3435 return "ConflictException" 3436} 3437 3438// Message returns the exception's message. 3439func (s *ConflictException) Message() string { 3440 if s.Message_ != nil { 3441 return *s.Message_ 3442 } 3443 return "" 3444} 3445 3446// OrigErr always returns nil, satisfies awserr.Error interface. 3447func (s *ConflictException) OrigErr() error { 3448 return nil 3449} 3450 3451func (s *ConflictException) Error() string { 3452 return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) 3453} 3454 3455// Status code returns the HTTP status code for the request's response error. 3456func (s *ConflictException) StatusCode() int { 3457 return s.RespMetadata.StatusCode 3458} 3459 3460// RequestID returns the service's response RequestID for request. 3461func (s *ConflictException) RequestID() string { 3462 return s.RespMetadata.RequestID 3463} 3464 3465type CreateDeviceInput struct { 3466 _ struct{} `type:"structure"` 3467 3468 // A description of the device. 3469 // 3470 // Length Constraints: Maximum length of 256 characters. 3471 Description *string `type:"string"` 3472 3473 // The ID of the global network. 3474 // 3475 // GlobalNetworkId is a required field 3476 GlobalNetworkId *string `location:"uri" locationName:"globalNetworkId" type:"string" required:"true"` 3477 3478 // The location of the device. 3479 Location *Location `type:"structure"` 3480 3481 // The model of the device. 3482 // 3483 // Length Constraints: Maximum length of 128 characters. 3484 Model *string `type:"string"` 3485 3486 // The serial number of the device. 3487 // 3488 // Length Constraints: Maximum length of 128 characters. 3489 SerialNumber *string `type:"string"` 3490 3491 // The ID of the site. 3492 SiteId *string `type:"string"` 3493 3494 // The tags to apply to the resource during creation. 3495 Tags []*Tag `type:"list"` 3496 3497 // The type of the device. 3498 Type *string `type:"string"` 3499 3500 // The vendor of the device. 3501 // 3502 // Length Constraints: Maximum length of 128 characters. 3503 Vendor *string `type:"string"` 3504} 3505 3506// String returns the string representation 3507func (s CreateDeviceInput) String() string { 3508 return awsutil.Prettify(s) 3509} 3510 3511// GoString returns the string representation 3512func (s CreateDeviceInput) GoString() string { 3513 return s.String() 3514} 3515 3516// Validate inspects the fields of the type to determine if they are valid. 3517func (s *CreateDeviceInput) Validate() error { 3518 invalidParams := request.ErrInvalidParams{Context: "CreateDeviceInput"} 3519 if s.GlobalNetworkId == nil { 3520 invalidParams.Add(request.NewErrParamRequired("GlobalNetworkId")) 3521 } 3522 if s.GlobalNetworkId != nil && len(*s.GlobalNetworkId) < 1 { 3523 invalidParams.Add(request.NewErrParamMinLen("GlobalNetworkId", 1)) 3524 } 3525 3526 if invalidParams.Len() > 0 { 3527 return invalidParams 3528 } 3529 return nil 3530} 3531 3532// SetDescription sets the Description field's value. 3533func (s *CreateDeviceInput) SetDescription(v string) *CreateDeviceInput { 3534 s.Description = &v 3535 return s 3536} 3537 3538// SetGlobalNetworkId sets the GlobalNetworkId field's value. 3539func (s *CreateDeviceInput) SetGlobalNetworkId(v string) *CreateDeviceInput { 3540 s.GlobalNetworkId = &v 3541 return s 3542} 3543 3544// SetLocation sets the Location field's value. 3545func (s *CreateDeviceInput) SetLocation(v *Location) *CreateDeviceInput { 3546 s.Location = v 3547 return s 3548} 3549 3550// SetModel sets the Model field's value. 3551func (s *CreateDeviceInput) SetModel(v string) *CreateDeviceInput { 3552 s.Model = &v 3553 return s 3554} 3555 3556// SetSerialNumber sets the SerialNumber field's value. 3557func (s *CreateDeviceInput) SetSerialNumber(v string) *CreateDeviceInput { 3558 s.SerialNumber = &v 3559 return s 3560} 3561 3562// SetSiteId sets the SiteId field's value. 3563func (s *CreateDeviceInput) SetSiteId(v string) *CreateDeviceInput { 3564 s.SiteId = &v 3565 return s 3566} 3567 3568// SetTags sets the Tags field's value. 3569func (s *CreateDeviceInput) SetTags(v []*Tag) *CreateDeviceInput { 3570 s.Tags = v 3571 return s 3572} 3573 3574// SetType sets the Type field's value. 3575func (s *CreateDeviceInput) SetType(v string) *CreateDeviceInput { 3576 s.Type = &v 3577 return s 3578} 3579 3580// SetVendor sets the Vendor field's value. 3581func (s *CreateDeviceInput) SetVendor(v string) *CreateDeviceInput { 3582 s.Vendor = &v 3583 return s 3584} 3585 3586type CreateDeviceOutput struct { 3587 _ struct{} `type:"structure"` 3588 3589 // Information about the device. 3590 Device *Device `type:"structure"` 3591} 3592 3593// String returns the string representation 3594func (s CreateDeviceOutput) String() string { 3595 return awsutil.Prettify(s) 3596} 3597 3598// GoString returns the string representation 3599func (s CreateDeviceOutput) GoString() string { 3600 return s.String() 3601} 3602 3603// SetDevice sets the Device field's value. 3604func (s *CreateDeviceOutput) SetDevice(v *Device) *CreateDeviceOutput { 3605 s.Device = v 3606 return s 3607} 3608 3609type CreateGlobalNetworkInput struct { 3610 _ struct{} `type:"structure"` 3611 3612 // A description of the global network. 3613 // 3614 // Length Constraints: Maximum length of 256 characters. 3615 Description *string `type:"string"` 3616 3617 // The tags to apply to the resource during creation. 3618 Tags []*Tag `type:"list"` 3619} 3620 3621// String returns the string representation 3622func (s CreateGlobalNetworkInput) String() string { 3623 return awsutil.Prettify(s) 3624} 3625 3626// GoString returns the string representation 3627func (s CreateGlobalNetworkInput) GoString() string { 3628 return s.String() 3629} 3630 3631// SetDescription sets the Description field's value. 3632func (s *CreateGlobalNetworkInput) SetDescription(v string) *CreateGlobalNetworkInput { 3633 s.Description = &v 3634 return s 3635} 3636 3637// SetTags sets the Tags field's value. 3638func (s *CreateGlobalNetworkInput) SetTags(v []*Tag) *CreateGlobalNetworkInput { 3639 s.Tags = v 3640 return s 3641} 3642 3643type CreateGlobalNetworkOutput struct { 3644 _ struct{} `type:"structure"` 3645 3646 // Information about the global network object. 3647 GlobalNetwork *GlobalNetwork `type:"structure"` 3648} 3649 3650// String returns the string representation 3651func (s CreateGlobalNetworkOutput) String() string { 3652 return awsutil.Prettify(s) 3653} 3654 3655// GoString returns the string representation 3656func (s CreateGlobalNetworkOutput) GoString() string { 3657 return s.String() 3658} 3659 3660// SetGlobalNetwork sets the GlobalNetwork field's value. 3661func (s *CreateGlobalNetworkOutput) SetGlobalNetwork(v *GlobalNetwork) *CreateGlobalNetworkOutput { 3662 s.GlobalNetwork = v 3663 return s 3664} 3665 3666type CreateLinkInput struct { 3667 _ struct{} `type:"structure"` 3668 3669 // The upload speed and download speed in Mbps. 3670 // 3671 // Bandwidth is a required field 3672 Bandwidth *Bandwidth `type:"structure" required:"true"` 3673 3674 // A description of the link. 3675 // 3676 // Length Constraints: Maximum length of 256 characters. 3677 Description *string `type:"string"` 3678 3679 // The ID of the global network. 3680 // 3681 // GlobalNetworkId is a required field 3682 GlobalNetworkId *string `location:"uri" locationName:"globalNetworkId" type:"string" required:"true"` 3683 3684 // The provider of the link. 3685 // 3686 // Constraints: Cannot include the following characters: | \ ^ 3687 // 3688 // Length Constraints: Maximum length of 128 characters. 3689 Provider *string `type:"string"` 3690 3691 // The ID of the site. 3692 // 3693 // SiteId is a required field 3694 SiteId *string `type:"string" required:"true"` 3695 3696 // The tags to apply to the resource during creation. 3697 Tags []*Tag `type:"list"` 3698 3699 // The type of the link. 3700 // 3701 // Constraints: Cannot include the following characters: | \ ^ 3702 // 3703 // Length Constraints: Maximum length of 128 characters. 3704 Type *string `type:"string"` 3705} 3706 3707// String returns the string representation 3708func (s CreateLinkInput) String() string { 3709 return awsutil.Prettify(s) 3710} 3711 3712// GoString returns the string representation 3713func (s CreateLinkInput) GoString() string { 3714 return s.String() 3715} 3716 3717// Validate inspects the fields of the type to determine if they are valid. 3718func (s *CreateLinkInput) Validate() error { 3719 invalidParams := request.ErrInvalidParams{Context: "CreateLinkInput"} 3720 if s.Bandwidth == nil { 3721 invalidParams.Add(request.NewErrParamRequired("Bandwidth")) 3722 } 3723 if s.GlobalNetworkId == nil { 3724 invalidParams.Add(request.NewErrParamRequired("GlobalNetworkId")) 3725 } 3726 if s.GlobalNetworkId != nil && len(*s.GlobalNetworkId) < 1 { 3727 invalidParams.Add(request.NewErrParamMinLen("GlobalNetworkId", 1)) 3728 } 3729 if s.SiteId == nil { 3730 invalidParams.Add(request.NewErrParamRequired("SiteId")) 3731 } 3732 3733 if invalidParams.Len() > 0 { 3734 return invalidParams 3735 } 3736 return nil 3737} 3738 3739// SetBandwidth sets the Bandwidth field's value. 3740func (s *CreateLinkInput) SetBandwidth(v *Bandwidth) *CreateLinkInput { 3741 s.Bandwidth = v 3742 return s 3743} 3744 3745// SetDescription sets the Description field's value. 3746func (s *CreateLinkInput) SetDescription(v string) *CreateLinkInput { 3747 s.Description = &v 3748 return s 3749} 3750 3751// SetGlobalNetworkId sets the GlobalNetworkId field's value. 3752func (s *CreateLinkInput) SetGlobalNetworkId(v string) *CreateLinkInput { 3753 s.GlobalNetworkId = &v 3754 return s 3755} 3756 3757// SetProvider sets the Provider field's value. 3758func (s *CreateLinkInput) SetProvider(v string) *CreateLinkInput { 3759 s.Provider = &v 3760 return s 3761} 3762 3763// SetSiteId sets the SiteId field's value. 3764func (s *CreateLinkInput) SetSiteId(v string) *CreateLinkInput { 3765 s.SiteId = &v 3766 return s 3767} 3768 3769// SetTags sets the Tags field's value. 3770func (s *CreateLinkInput) SetTags(v []*Tag) *CreateLinkInput { 3771 s.Tags = v 3772 return s 3773} 3774 3775// SetType sets the Type field's value. 3776func (s *CreateLinkInput) SetType(v string) *CreateLinkInput { 3777 s.Type = &v 3778 return s 3779} 3780 3781type CreateLinkOutput struct { 3782 _ struct{} `type:"structure"` 3783 3784 // Information about the link. 3785 Link *Link `type:"structure"` 3786} 3787 3788// String returns the string representation 3789func (s CreateLinkOutput) String() string { 3790 return awsutil.Prettify(s) 3791} 3792 3793// GoString returns the string representation 3794func (s CreateLinkOutput) GoString() string { 3795 return s.String() 3796} 3797 3798// SetLink sets the Link field's value. 3799func (s *CreateLinkOutput) SetLink(v *Link) *CreateLinkOutput { 3800 s.Link = v 3801 return s 3802} 3803 3804type CreateSiteInput struct { 3805 _ struct{} `type:"structure"` 3806 3807 // A description of your site. 3808 // 3809 // Length Constraints: Maximum length of 256 characters. 3810 Description *string `type:"string"` 3811 3812 // The ID of the global network. 3813 // 3814 // GlobalNetworkId is a required field 3815 GlobalNetworkId *string `location:"uri" locationName:"globalNetworkId" type:"string" required:"true"` 3816 3817 // The site location. This information is used for visualization in the Network 3818 // Manager console. If you specify the address, the latitude and longitude are 3819 // automatically calculated. 3820 // 3821 // * Address: The physical address of the site. 3822 // 3823 // * Latitude: The latitude of the site. 3824 // 3825 // * Longitude: The longitude of the site. 3826 Location *Location `type:"structure"` 3827 3828 // The tags to apply to the resource during creation. 3829 Tags []*Tag `type:"list"` 3830} 3831 3832// String returns the string representation 3833func (s CreateSiteInput) String() string { 3834 return awsutil.Prettify(s) 3835} 3836 3837// GoString returns the string representation 3838func (s CreateSiteInput) GoString() string { 3839 return s.String() 3840} 3841 3842// Validate inspects the fields of the type to determine if they are valid. 3843func (s *CreateSiteInput) Validate() error { 3844 invalidParams := request.ErrInvalidParams{Context: "CreateSiteInput"} 3845 if s.GlobalNetworkId == nil { 3846 invalidParams.Add(request.NewErrParamRequired("GlobalNetworkId")) 3847 } 3848 if s.GlobalNetworkId != nil && len(*s.GlobalNetworkId) < 1 { 3849 invalidParams.Add(request.NewErrParamMinLen("GlobalNetworkId", 1)) 3850 } 3851 3852 if invalidParams.Len() > 0 { 3853 return invalidParams 3854 } 3855 return nil 3856} 3857 3858// SetDescription sets the Description field's value. 3859func (s *CreateSiteInput) SetDescription(v string) *CreateSiteInput { 3860 s.Description = &v 3861 return s 3862} 3863 3864// SetGlobalNetworkId sets the GlobalNetworkId field's value. 3865func (s *CreateSiteInput) SetGlobalNetworkId(v string) *CreateSiteInput { 3866 s.GlobalNetworkId = &v 3867 return s 3868} 3869 3870// SetLocation sets the Location field's value. 3871func (s *CreateSiteInput) SetLocation(v *Location) *CreateSiteInput { 3872 s.Location = v 3873 return s 3874} 3875 3876// SetTags sets the Tags field's value. 3877func (s *CreateSiteInput) SetTags(v []*Tag) *CreateSiteInput { 3878 s.Tags = v 3879 return s 3880} 3881 3882type CreateSiteOutput struct { 3883 _ struct{} `type:"structure"` 3884 3885 // Information about the site. 3886 Site *Site `type:"structure"` 3887} 3888 3889// String returns the string representation 3890func (s CreateSiteOutput) String() string { 3891 return awsutil.Prettify(s) 3892} 3893 3894// GoString returns the string representation 3895func (s CreateSiteOutput) GoString() string { 3896 return s.String() 3897} 3898 3899// SetSite sets the Site field's value. 3900func (s *CreateSiteOutput) SetSite(v *Site) *CreateSiteOutput { 3901 s.Site = v 3902 return s 3903} 3904 3905// Describes the association between a customer gateway, a device, and a link. 3906type CustomerGatewayAssociation struct { 3907 _ struct{} `type:"structure"` 3908 3909 // The Amazon Resource Name (ARN) of the customer gateway. 3910 CustomerGatewayArn *string `type:"string"` 3911 3912 // The ID of the device. 3913 DeviceId *string `type:"string"` 3914 3915 // The ID of the global network. 3916 GlobalNetworkId *string `type:"string"` 3917 3918 // The ID of the link. 3919 LinkId *string `type:"string"` 3920 3921 // The association state. 3922 State *string `type:"string" enum:"CustomerGatewayAssociationState"` 3923} 3924 3925// String returns the string representation 3926func (s CustomerGatewayAssociation) String() string { 3927 return awsutil.Prettify(s) 3928} 3929 3930// GoString returns the string representation 3931func (s CustomerGatewayAssociation) GoString() string { 3932 return s.String() 3933} 3934 3935// SetCustomerGatewayArn sets the CustomerGatewayArn field's value. 3936func (s *CustomerGatewayAssociation) SetCustomerGatewayArn(v string) *CustomerGatewayAssociation { 3937 s.CustomerGatewayArn = &v 3938 return s 3939} 3940 3941// SetDeviceId sets the DeviceId field's value. 3942func (s *CustomerGatewayAssociation) SetDeviceId(v string) *CustomerGatewayAssociation { 3943 s.DeviceId = &v 3944 return s 3945} 3946 3947// SetGlobalNetworkId sets the GlobalNetworkId field's value. 3948func (s *CustomerGatewayAssociation) SetGlobalNetworkId(v string) *CustomerGatewayAssociation { 3949 s.GlobalNetworkId = &v 3950 return s 3951} 3952 3953// SetLinkId sets the LinkId field's value. 3954func (s *CustomerGatewayAssociation) SetLinkId(v string) *CustomerGatewayAssociation { 3955 s.LinkId = &v 3956 return s 3957} 3958 3959// SetState sets the State field's value. 3960func (s *CustomerGatewayAssociation) SetState(v string) *CustomerGatewayAssociation { 3961 s.State = &v 3962 return s 3963} 3964 3965type DeleteDeviceInput struct { 3966 _ struct{} `type:"structure"` 3967 3968 // The ID of the device. 3969 // 3970 // DeviceId is a required field 3971 DeviceId *string `location:"uri" locationName:"deviceId" type:"string" required:"true"` 3972 3973 // The ID of the global network. 3974 // 3975 // GlobalNetworkId is a required field 3976 GlobalNetworkId *string `location:"uri" locationName:"globalNetworkId" type:"string" required:"true"` 3977} 3978 3979// String returns the string representation 3980func (s DeleteDeviceInput) String() string { 3981 return awsutil.Prettify(s) 3982} 3983 3984// GoString returns the string representation 3985func (s DeleteDeviceInput) GoString() string { 3986 return s.String() 3987} 3988 3989// Validate inspects the fields of the type to determine if they are valid. 3990func (s *DeleteDeviceInput) Validate() error { 3991 invalidParams := request.ErrInvalidParams{Context: "DeleteDeviceInput"} 3992 if s.DeviceId == nil { 3993 invalidParams.Add(request.NewErrParamRequired("DeviceId")) 3994 } 3995 if s.DeviceId != nil && len(*s.DeviceId) < 1 { 3996 invalidParams.Add(request.NewErrParamMinLen("DeviceId", 1)) 3997 } 3998 if s.GlobalNetworkId == nil { 3999 invalidParams.Add(request.NewErrParamRequired("GlobalNetworkId")) 4000 } 4001 if s.GlobalNetworkId != nil && len(*s.GlobalNetworkId) < 1 { 4002 invalidParams.Add(request.NewErrParamMinLen("GlobalNetworkId", 1)) 4003 } 4004 4005 if invalidParams.Len() > 0 { 4006 return invalidParams 4007 } 4008 return nil 4009} 4010 4011// SetDeviceId sets the DeviceId field's value. 4012func (s *DeleteDeviceInput) SetDeviceId(v string) *DeleteDeviceInput { 4013 s.DeviceId = &v 4014 return s 4015} 4016 4017// SetGlobalNetworkId sets the GlobalNetworkId field's value. 4018func (s *DeleteDeviceInput) SetGlobalNetworkId(v string) *DeleteDeviceInput { 4019 s.GlobalNetworkId = &v 4020 return s 4021} 4022 4023type DeleteDeviceOutput struct { 4024 _ struct{} `type:"structure"` 4025 4026 // Information about the device. 4027 Device *Device `type:"structure"` 4028} 4029 4030// String returns the string representation 4031func (s DeleteDeviceOutput) String() string { 4032 return awsutil.Prettify(s) 4033} 4034 4035// GoString returns the string representation 4036func (s DeleteDeviceOutput) GoString() string { 4037 return s.String() 4038} 4039 4040// SetDevice sets the Device field's value. 4041func (s *DeleteDeviceOutput) SetDevice(v *Device) *DeleteDeviceOutput { 4042 s.Device = v 4043 return s 4044} 4045 4046type DeleteGlobalNetworkInput struct { 4047 _ struct{} `type:"structure"` 4048 4049 // The ID of the global network. 4050 // 4051 // GlobalNetworkId is a required field 4052 GlobalNetworkId *string `location:"uri" locationName:"globalNetworkId" type:"string" required:"true"` 4053} 4054 4055// String returns the string representation 4056func (s DeleteGlobalNetworkInput) String() string { 4057 return awsutil.Prettify(s) 4058} 4059 4060// GoString returns the string representation 4061func (s DeleteGlobalNetworkInput) GoString() string { 4062 return s.String() 4063} 4064 4065// Validate inspects the fields of the type to determine if they are valid. 4066func (s *DeleteGlobalNetworkInput) Validate() error { 4067 invalidParams := request.ErrInvalidParams{Context: "DeleteGlobalNetworkInput"} 4068 if s.GlobalNetworkId == nil { 4069 invalidParams.Add(request.NewErrParamRequired("GlobalNetworkId")) 4070 } 4071 if s.GlobalNetworkId != nil && len(*s.GlobalNetworkId) < 1 { 4072 invalidParams.Add(request.NewErrParamMinLen("GlobalNetworkId", 1)) 4073 } 4074 4075 if invalidParams.Len() > 0 { 4076 return invalidParams 4077 } 4078 return nil 4079} 4080 4081// SetGlobalNetworkId sets the GlobalNetworkId field's value. 4082func (s *DeleteGlobalNetworkInput) SetGlobalNetworkId(v string) *DeleteGlobalNetworkInput { 4083 s.GlobalNetworkId = &v 4084 return s 4085} 4086 4087type DeleteGlobalNetworkOutput struct { 4088 _ struct{} `type:"structure"` 4089 4090 // Information about the global network. 4091 GlobalNetwork *GlobalNetwork `type:"structure"` 4092} 4093 4094// String returns the string representation 4095func (s DeleteGlobalNetworkOutput) String() string { 4096 return awsutil.Prettify(s) 4097} 4098 4099// GoString returns the string representation 4100func (s DeleteGlobalNetworkOutput) GoString() string { 4101 return s.String() 4102} 4103 4104// SetGlobalNetwork sets the GlobalNetwork field's value. 4105func (s *DeleteGlobalNetworkOutput) SetGlobalNetwork(v *GlobalNetwork) *DeleteGlobalNetworkOutput { 4106 s.GlobalNetwork = v 4107 return s 4108} 4109 4110type DeleteLinkInput struct { 4111 _ struct{} `type:"structure"` 4112 4113 // The ID of the global network. 4114 // 4115 // GlobalNetworkId is a required field 4116 GlobalNetworkId *string `location:"uri" locationName:"globalNetworkId" type:"string" required:"true"` 4117 4118 // The ID of the link. 4119 // 4120 // LinkId is a required field 4121 LinkId *string `location:"uri" locationName:"linkId" type:"string" required:"true"` 4122} 4123 4124// String returns the string representation 4125func (s DeleteLinkInput) String() string { 4126 return awsutil.Prettify(s) 4127} 4128 4129// GoString returns the string representation 4130func (s DeleteLinkInput) GoString() string { 4131 return s.String() 4132} 4133 4134// Validate inspects the fields of the type to determine if they are valid. 4135func (s *DeleteLinkInput) Validate() error { 4136 invalidParams := request.ErrInvalidParams{Context: "DeleteLinkInput"} 4137 if s.GlobalNetworkId == nil { 4138 invalidParams.Add(request.NewErrParamRequired("GlobalNetworkId")) 4139 } 4140 if s.GlobalNetworkId != nil && len(*s.GlobalNetworkId) < 1 { 4141 invalidParams.Add(request.NewErrParamMinLen("GlobalNetworkId", 1)) 4142 } 4143 if s.LinkId == nil { 4144 invalidParams.Add(request.NewErrParamRequired("LinkId")) 4145 } 4146 if s.LinkId != nil && len(*s.LinkId) < 1 { 4147 invalidParams.Add(request.NewErrParamMinLen("LinkId", 1)) 4148 } 4149 4150 if invalidParams.Len() > 0 { 4151 return invalidParams 4152 } 4153 return nil 4154} 4155 4156// SetGlobalNetworkId sets the GlobalNetworkId field's value. 4157func (s *DeleteLinkInput) SetGlobalNetworkId(v string) *DeleteLinkInput { 4158 s.GlobalNetworkId = &v 4159 return s 4160} 4161 4162// SetLinkId sets the LinkId field's value. 4163func (s *DeleteLinkInput) SetLinkId(v string) *DeleteLinkInput { 4164 s.LinkId = &v 4165 return s 4166} 4167 4168type DeleteLinkOutput struct { 4169 _ struct{} `type:"structure"` 4170 4171 // Information about the link. 4172 Link *Link `type:"structure"` 4173} 4174 4175// String returns the string representation 4176func (s DeleteLinkOutput) String() string { 4177 return awsutil.Prettify(s) 4178} 4179 4180// GoString returns the string representation 4181func (s DeleteLinkOutput) GoString() string { 4182 return s.String() 4183} 4184 4185// SetLink sets the Link field's value. 4186func (s *DeleteLinkOutput) SetLink(v *Link) *DeleteLinkOutput { 4187 s.Link = v 4188 return s 4189} 4190 4191type DeleteSiteInput struct { 4192 _ struct{} `type:"structure"` 4193 4194 // The ID of the global network. 4195 // 4196 // GlobalNetworkId is a required field 4197 GlobalNetworkId *string `location:"uri" locationName:"globalNetworkId" type:"string" required:"true"` 4198 4199 // The ID of the site. 4200 // 4201 // SiteId is a required field 4202 SiteId *string `location:"uri" locationName:"siteId" type:"string" required:"true"` 4203} 4204 4205// String returns the string representation 4206func (s DeleteSiteInput) String() string { 4207 return awsutil.Prettify(s) 4208} 4209 4210// GoString returns the string representation 4211func (s DeleteSiteInput) GoString() string { 4212 return s.String() 4213} 4214 4215// Validate inspects the fields of the type to determine if they are valid. 4216func (s *DeleteSiteInput) Validate() error { 4217 invalidParams := request.ErrInvalidParams{Context: "DeleteSiteInput"} 4218 if s.GlobalNetworkId == nil { 4219 invalidParams.Add(request.NewErrParamRequired("GlobalNetworkId")) 4220 } 4221 if s.GlobalNetworkId != nil && len(*s.GlobalNetworkId) < 1 { 4222 invalidParams.Add(request.NewErrParamMinLen("GlobalNetworkId", 1)) 4223 } 4224 if s.SiteId == nil { 4225 invalidParams.Add(request.NewErrParamRequired("SiteId")) 4226 } 4227 if s.SiteId != nil && len(*s.SiteId) < 1 { 4228 invalidParams.Add(request.NewErrParamMinLen("SiteId", 1)) 4229 } 4230 4231 if invalidParams.Len() > 0 { 4232 return invalidParams 4233 } 4234 return nil 4235} 4236 4237// SetGlobalNetworkId sets the GlobalNetworkId field's value. 4238func (s *DeleteSiteInput) SetGlobalNetworkId(v string) *DeleteSiteInput { 4239 s.GlobalNetworkId = &v 4240 return s 4241} 4242 4243// SetSiteId sets the SiteId field's value. 4244func (s *DeleteSiteInput) SetSiteId(v string) *DeleteSiteInput { 4245 s.SiteId = &v 4246 return s 4247} 4248 4249type DeleteSiteOutput struct { 4250 _ struct{} `type:"structure"` 4251 4252 // Information about the site. 4253 Site *Site `type:"structure"` 4254} 4255 4256// String returns the string representation 4257func (s DeleteSiteOutput) String() string { 4258 return awsutil.Prettify(s) 4259} 4260 4261// GoString returns the string representation 4262func (s DeleteSiteOutput) GoString() string { 4263 return s.String() 4264} 4265 4266// SetSite sets the Site field's value. 4267func (s *DeleteSiteOutput) SetSite(v *Site) *DeleteSiteOutput { 4268 s.Site = v 4269 return s 4270} 4271 4272type DeregisterTransitGatewayInput struct { 4273 _ struct{} `type:"structure"` 4274 4275 // The ID of the global network. 4276 // 4277 // GlobalNetworkId is a required field 4278 GlobalNetworkId *string `location:"uri" locationName:"globalNetworkId" type:"string" required:"true"` 4279 4280 // The Amazon Resource Name (ARN) of the transit gateway. 4281 // 4282 // TransitGatewayArn is a required field 4283 TransitGatewayArn *string `location:"uri" locationName:"transitGatewayArn" type:"string" required:"true"` 4284} 4285 4286// String returns the string representation 4287func (s DeregisterTransitGatewayInput) String() string { 4288 return awsutil.Prettify(s) 4289} 4290 4291// GoString returns the string representation 4292func (s DeregisterTransitGatewayInput) GoString() string { 4293 return s.String() 4294} 4295 4296// Validate inspects the fields of the type to determine if they are valid. 4297func (s *DeregisterTransitGatewayInput) Validate() error { 4298 invalidParams := request.ErrInvalidParams{Context: "DeregisterTransitGatewayInput"} 4299 if s.GlobalNetworkId == nil { 4300 invalidParams.Add(request.NewErrParamRequired("GlobalNetworkId")) 4301 } 4302 if s.GlobalNetworkId != nil && len(*s.GlobalNetworkId) < 1 { 4303 invalidParams.Add(request.NewErrParamMinLen("GlobalNetworkId", 1)) 4304 } 4305 if s.TransitGatewayArn == nil { 4306 invalidParams.Add(request.NewErrParamRequired("TransitGatewayArn")) 4307 } 4308 if s.TransitGatewayArn != nil && len(*s.TransitGatewayArn) < 1 { 4309 invalidParams.Add(request.NewErrParamMinLen("TransitGatewayArn", 1)) 4310 } 4311 4312 if invalidParams.Len() > 0 { 4313 return invalidParams 4314 } 4315 return nil 4316} 4317 4318// SetGlobalNetworkId sets the GlobalNetworkId field's value. 4319func (s *DeregisterTransitGatewayInput) SetGlobalNetworkId(v string) *DeregisterTransitGatewayInput { 4320 s.GlobalNetworkId = &v 4321 return s 4322} 4323 4324// SetTransitGatewayArn sets the TransitGatewayArn field's value. 4325func (s *DeregisterTransitGatewayInput) SetTransitGatewayArn(v string) *DeregisterTransitGatewayInput { 4326 s.TransitGatewayArn = &v 4327 return s 4328} 4329 4330type DeregisterTransitGatewayOutput struct { 4331 _ struct{} `type:"structure"` 4332 4333 // The transit gateway registration information. 4334 TransitGatewayRegistration *TransitGatewayRegistration `type:"structure"` 4335} 4336 4337// String returns the string representation 4338func (s DeregisterTransitGatewayOutput) String() string { 4339 return awsutil.Prettify(s) 4340} 4341 4342// GoString returns the string representation 4343func (s DeregisterTransitGatewayOutput) GoString() string { 4344 return s.String() 4345} 4346 4347// SetTransitGatewayRegistration sets the TransitGatewayRegistration field's value. 4348func (s *DeregisterTransitGatewayOutput) SetTransitGatewayRegistration(v *TransitGatewayRegistration) *DeregisterTransitGatewayOutput { 4349 s.TransitGatewayRegistration = v 4350 return s 4351} 4352 4353type DescribeGlobalNetworksInput struct { 4354 _ struct{} `type:"structure"` 4355 4356 // The IDs of one or more global networks. The maximum is 10. 4357 GlobalNetworkIds []*string `location:"querystring" locationName:"globalNetworkIds" type:"list"` 4358 4359 // The maximum number of results to return. 4360 MaxResults *int64 `location:"querystring" locationName:"maxResults" min:"1" type:"integer"` 4361 4362 // The token for the next page of results. 4363 NextToken *string `location:"querystring" locationName:"nextToken" type:"string"` 4364} 4365 4366// String returns the string representation 4367func (s DescribeGlobalNetworksInput) String() string { 4368 return awsutil.Prettify(s) 4369} 4370 4371// GoString returns the string representation 4372func (s DescribeGlobalNetworksInput) GoString() string { 4373 return s.String() 4374} 4375 4376// Validate inspects the fields of the type to determine if they are valid. 4377func (s *DescribeGlobalNetworksInput) Validate() error { 4378 invalidParams := request.ErrInvalidParams{Context: "DescribeGlobalNetworksInput"} 4379 if s.MaxResults != nil && *s.MaxResults < 1 { 4380 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 4381 } 4382 4383 if invalidParams.Len() > 0 { 4384 return invalidParams 4385 } 4386 return nil 4387} 4388 4389// SetGlobalNetworkIds sets the GlobalNetworkIds field's value. 4390func (s *DescribeGlobalNetworksInput) SetGlobalNetworkIds(v []*string) *DescribeGlobalNetworksInput { 4391 s.GlobalNetworkIds = v 4392 return s 4393} 4394 4395// SetMaxResults sets the MaxResults field's value. 4396func (s *DescribeGlobalNetworksInput) SetMaxResults(v int64) *DescribeGlobalNetworksInput { 4397 s.MaxResults = &v 4398 return s 4399} 4400 4401// SetNextToken sets the NextToken field's value. 4402func (s *DescribeGlobalNetworksInput) SetNextToken(v string) *DescribeGlobalNetworksInput { 4403 s.NextToken = &v 4404 return s 4405} 4406 4407type DescribeGlobalNetworksOutput struct { 4408 _ struct{} `type:"structure"` 4409 4410 // Information about the global networks. 4411 GlobalNetworks []*GlobalNetwork `type:"list"` 4412 4413 // The token for the next page of results. 4414 NextToken *string `type:"string"` 4415} 4416 4417// String returns the string representation 4418func (s DescribeGlobalNetworksOutput) String() string { 4419 return awsutil.Prettify(s) 4420} 4421 4422// GoString returns the string representation 4423func (s DescribeGlobalNetworksOutput) GoString() string { 4424 return s.String() 4425} 4426 4427// SetGlobalNetworks sets the GlobalNetworks field's value. 4428func (s *DescribeGlobalNetworksOutput) SetGlobalNetworks(v []*GlobalNetwork) *DescribeGlobalNetworksOutput { 4429 s.GlobalNetworks = v 4430 return s 4431} 4432 4433// SetNextToken sets the NextToken field's value. 4434func (s *DescribeGlobalNetworksOutput) SetNextToken(v string) *DescribeGlobalNetworksOutput { 4435 s.NextToken = &v 4436 return s 4437} 4438 4439// Describes a device. 4440type Device struct { 4441 _ struct{} `type:"structure"` 4442 4443 // The date and time that the site was created. 4444 CreatedAt *time.Time `type:"timestamp"` 4445 4446 // The description of the device. 4447 Description *string `type:"string"` 4448 4449 // The Amazon Resource Name (ARN) of the device. 4450 DeviceArn *string `type:"string"` 4451 4452 // The ID of the device. 4453 DeviceId *string `type:"string"` 4454 4455 // The ID of the global network. 4456 GlobalNetworkId *string `type:"string"` 4457 4458 // The site location. 4459 Location *Location `type:"structure"` 4460 4461 // The device model. 4462 Model *string `type:"string"` 4463 4464 // The device serial number. 4465 SerialNumber *string `type:"string"` 4466 4467 // The site ID. 4468 SiteId *string `type:"string"` 4469 4470 // The device state. 4471 State *string `type:"string" enum:"DeviceState"` 4472 4473 // The tags for the device. 4474 Tags []*Tag `type:"list"` 4475 4476 // The device type. 4477 Type *string `type:"string"` 4478 4479 // The device vendor. 4480 Vendor *string `type:"string"` 4481} 4482 4483// String returns the string representation 4484func (s Device) String() string { 4485 return awsutil.Prettify(s) 4486} 4487 4488// GoString returns the string representation 4489func (s Device) GoString() string { 4490 return s.String() 4491} 4492 4493// SetCreatedAt sets the CreatedAt field's value. 4494func (s *Device) SetCreatedAt(v time.Time) *Device { 4495 s.CreatedAt = &v 4496 return s 4497} 4498 4499// SetDescription sets the Description field's value. 4500func (s *Device) SetDescription(v string) *Device { 4501 s.Description = &v 4502 return s 4503} 4504 4505// SetDeviceArn sets the DeviceArn field's value. 4506func (s *Device) SetDeviceArn(v string) *Device { 4507 s.DeviceArn = &v 4508 return s 4509} 4510 4511// SetDeviceId sets the DeviceId field's value. 4512func (s *Device) SetDeviceId(v string) *Device { 4513 s.DeviceId = &v 4514 return s 4515} 4516 4517// SetGlobalNetworkId sets the GlobalNetworkId field's value. 4518func (s *Device) SetGlobalNetworkId(v string) *Device { 4519 s.GlobalNetworkId = &v 4520 return s 4521} 4522 4523// SetLocation sets the Location field's value. 4524func (s *Device) SetLocation(v *Location) *Device { 4525 s.Location = v 4526 return s 4527} 4528 4529// SetModel sets the Model field's value. 4530func (s *Device) SetModel(v string) *Device { 4531 s.Model = &v 4532 return s 4533} 4534 4535// SetSerialNumber sets the SerialNumber field's value. 4536func (s *Device) SetSerialNumber(v string) *Device { 4537 s.SerialNumber = &v 4538 return s 4539} 4540 4541// SetSiteId sets the SiteId field's value. 4542func (s *Device) SetSiteId(v string) *Device { 4543 s.SiteId = &v 4544 return s 4545} 4546 4547// SetState sets the State field's value. 4548func (s *Device) SetState(v string) *Device { 4549 s.State = &v 4550 return s 4551} 4552 4553// SetTags sets the Tags field's value. 4554func (s *Device) SetTags(v []*Tag) *Device { 4555 s.Tags = v 4556 return s 4557} 4558 4559// SetType sets the Type field's value. 4560func (s *Device) SetType(v string) *Device { 4561 s.Type = &v 4562 return s 4563} 4564 4565// SetVendor sets the Vendor field's value. 4566func (s *Device) SetVendor(v string) *Device { 4567 s.Vendor = &v 4568 return s 4569} 4570 4571type DisassociateCustomerGatewayInput struct { 4572 _ struct{} `type:"structure"` 4573 4574 // The Amazon Resource Name (ARN) of the customer gateway. For more information, 4575 // see Resources Defined by Amazon EC2 (https://docs.aws.amazon.com/IAM/latest/UserGuide/list_amazonec2.html#amazonec2-resources-for-iam-policies). 4576 // 4577 // CustomerGatewayArn is a required field 4578 CustomerGatewayArn *string `location:"uri" locationName:"customerGatewayArn" type:"string" required:"true"` 4579 4580 // The ID of the global network. 4581 // 4582 // GlobalNetworkId is a required field 4583 GlobalNetworkId *string `location:"uri" locationName:"globalNetworkId" type:"string" required:"true"` 4584} 4585 4586// String returns the string representation 4587func (s DisassociateCustomerGatewayInput) String() string { 4588 return awsutil.Prettify(s) 4589} 4590 4591// GoString returns the string representation 4592func (s DisassociateCustomerGatewayInput) GoString() string { 4593 return s.String() 4594} 4595 4596// Validate inspects the fields of the type to determine if they are valid. 4597func (s *DisassociateCustomerGatewayInput) Validate() error { 4598 invalidParams := request.ErrInvalidParams{Context: "DisassociateCustomerGatewayInput"} 4599 if s.CustomerGatewayArn == nil { 4600 invalidParams.Add(request.NewErrParamRequired("CustomerGatewayArn")) 4601 } 4602 if s.CustomerGatewayArn != nil && len(*s.CustomerGatewayArn) < 1 { 4603 invalidParams.Add(request.NewErrParamMinLen("CustomerGatewayArn", 1)) 4604 } 4605 if s.GlobalNetworkId == nil { 4606 invalidParams.Add(request.NewErrParamRequired("GlobalNetworkId")) 4607 } 4608 if s.GlobalNetworkId != nil && len(*s.GlobalNetworkId) < 1 { 4609 invalidParams.Add(request.NewErrParamMinLen("GlobalNetworkId", 1)) 4610 } 4611 4612 if invalidParams.Len() > 0 { 4613 return invalidParams 4614 } 4615 return nil 4616} 4617 4618// SetCustomerGatewayArn sets the CustomerGatewayArn field's value. 4619func (s *DisassociateCustomerGatewayInput) SetCustomerGatewayArn(v string) *DisassociateCustomerGatewayInput { 4620 s.CustomerGatewayArn = &v 4621 return s 4622} 4623 4624// SetGlobalNetworkId sets the GlobalNetworkId field's value. 4625func (s *DisassociateCustomerGatewayInput) SetGlobalNetworkId(v string) *DisassociateCustomerGatewayInput { 4626 s.GlobalNetworkId = &v 4627 return s 4628} 4629 4630type DisassociateCustomerGatewayOutput struct { 4631 _ struct{} `type:"structure"` 4632 4633 // Information about the customer gateway association. 4634 CustomerGatewayAssociation *CustomerGatewayAssociation `type:"structure"` 4635} 4636 4637// String returns the string representation 4638func (s DisassociateCustomerGatewayOutput) String() string { 4639 return awsutil.Prettify(s) 4640} 4641 4642// GoString returns the string representation 4643func (s DisassociateCustomerGatewayOutput) GoString() string { 4644 return s.String() 4645} 4646 4647// SetCustomerGatewayAssociation sets the CustomerGatewayAssociation field's value. 4648func (s *DisassociateCustomerGatewayOutput) SetCustomerGatewayAssociation(v *CustomerGatewayAssociation) *DisassociateCustomerGatewayOutput { 4649 s.CustomerGatewayAssociation = v 4650 return s 4651} 4652 4653type DisassociateLinkInput struct { 4654 _ struct{} `type:"structure"` 4655 4656 // The ID of the device. 4657 // 4658 // DeviceId is a required field 4659 DeviceId *string `location:"querystring" locationName:"deviceId" type:"string" required:"true"` 4660 4661 // The ID of the global network. 4662 // 4663 // GlobalNetworkId is a required field 4664 GlobalNetworkId *string `location:"uri" locationName:"globalNetworkId" type:"string" required:"true"` 4665 4666 // The ID of the link. 4667 // 4668 // LinkId is a required field 4669 LinkId *string `location:"querystring" locationName:"linkId" type:"string" required:"true"` 4670} 4671 4672// String returns the string representation 4673func (s DisassociateLinkInput) String() string { 4674 return awsutil.Prettify(s) 4675} 4676 4677// GoString returns the string representation 4678func (s DisassociateLinkInput) GoString() string { 4679 return s.String() 4680} 4681 4682// Validate inspects the fields of the type to determine if they are valid. 4683func (s *DisassociateLinkInput) Validate() error { 4684 invalidParams := request.ErrInvalidParams{Context: "DisassociateLinkInput"} 4685 if s.DeviceId == nil { 4686 invalidParams.Add(request.NewErrParamRequired("DeviceId")) 4687 } 4688 if s.GlobalNetworkId == nil { 4689 invalidParams.Add(request.NewErrParamRequired("GlobalNetworkId")) 4690 } 4691 if s.GlobalNetworkId != nil && len(*s.GlobalNetworkId) < 1 { 4692 invalidParams.Add(request.NewErrParamMinLen("GlobalNetworkId", 1)) 4693 } 4694 if s.LinkId == nil { 4695 invalidParams.Add(request.NewErrParamRequired("LinkId")) 4696 } 4697 4698 if invalidParams.Len() > 0 { 4699 return invalidParams 4700 } 4701 return nil 4702} 4703 4704// SetDeviceId sets the DeviceId field's value. 4705func (s *DisassociateLinkInput) SetDeviceId(v string) *DisassociateLinkInput { 4706 s.DeviceId = &v 4707 return s 4708} 4709 4710// SetGlobalNetworkId sets the GlobalNetworkId field's value. 4711func (s *DisassociateLinkInput) SetGlobalNetworkId(v string) *DisassociateLinkInput { 4712 s.GlobalNetworkId = &v 4713 return s 4714} 4715 4716// SetLinkId sets the LinkId field's value. 4717func (s *DisassociateLinkInput) SetLinkId(v string) *DisassociateLinkInput { 4718 s.LinkId = &v 4719 return s 4720} 4721 4722type DisassociateLinkOutput struct { 4723 _ struct{} `type:"structure"` 4724 4725 // Information about the link association. 4726 LinkAssociation *LinkAssociation `type:"structure"` 4727} 4728 4729// String returns the string representation 4730func (s DisassociateLinkOutput) String() string { 4731 return awsutil.Prettify(s) 4732} 4733 4734// GoString returns the string representation 4735func (s DisassociateLinkOutput) GoString() string { 4736 return s.String() 4737} 4738 4739// SetLinkAssociation sets the LinkAssociation field's value. 4740func (s *DisassociateLinkOutput) SetLinkAssociation(v *LinkAssociation) *DisassociateLinkOutput { 4741 s.LinkAssociation = v 4742 return s 4743} 4744 4745type GetCustomerGatewayAssociationsInput struct { 4746 _ struct{} `type:"structure"` 4747 4748 // One or more customer gateway Amazon Resource Names (ARNs). For more information, 4749 // see Resources Defined by Amazon EC2 (https://docs.aws.amazon.com/IAM/latest/UserGuide/list_amazonec2.html#amazonec2-resources-for-iam-policies). 4750 // The maximum is 10. 4751 CustomerGatewayArns []*string `location:"querystring" locationName:"customerGatewayArns" type:"list"` 4752 4753 // The ID of the global network. 4754 // 4755 // GlobalNetworkId is a required field 4756 GlobalNetworkId *string `location:"uri" locationName:"globalNetworkId" type:"string" required:"true"` 4757 4758 // The maximum number of results to return. 4759 MaxResults *int64 `location:"querystring" locationName:"maxResults" min:"1" type:"integer"` 4760 4761 // The token for the next page of results. 4762 NextToken *string `location:"querystring" locationName:"nextToken" type:"string"` 4763} 4764 4765// String returns the string representation 4766func (s GetCustomerGatewayAssociationsInput) String() string { 4767 return awsutil.Prettify(s) 4768} 4769 4770// GoString returns the string representation 4771func (s GetCustomerGatewayAssociationsInput) GoString() string { 4772 return s.String() 4773} 4774 4775// Validate inspects the fields of the type to determine if they are valid. 4776func (s *GetCustomerGatewayAssociationsInput) Validate() error { 4777 invalidParams := request.ErrInvalidParams{Context: "GetCustomerGatewayAssociationsInput"} 4778 if s.GlobalNetworkId == nil { 4779 invalidParams.Add(request.NewErrParamRequired("GlobalNetworkId")) 4780 } 4781 if s.GlobalNetworkId != nil && len(*s.GlobalNetworkId) < 1 { 4782 invalidParams.Add(request.NewErrParamMinLen("GlobalNetworkId", 1)) 4783 } 4784 if s.MaxResults != nil && *s.MaxResults < 1 { 4785 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 4786 } 4787 4788 if invalidParams.Len() > 0 { 4789 return invalidParams 4790 } 4791 return nil 4792} 4793 4794// SetCustomerGatewayArns sets the CustomerGatewayArns field's value. 4795func (s *GetCustomerGatewayAssociationsInput) SetCustomerGatewayArns(v []*string) *GetCustomerGatewayAssociationsInput { 4796 s.CustomerGatewayArns = v 4797 return s 4798} 4799 4800// SetGlobalNetworkId sets the GlobalNetworkId field's value. 4801func (s *GetCustomerGatewayAssociationsInput) SetGlobalNetworkId(v string) *GetCustomerGatewayAssociationsInput { 4802 s.GlobalNetworkId = &v 4803 return s 4804} 4805 4806// SetMaxResults sets the MaxResults field's value. 4807func (s *GetCustomerGatewayAssociationsInput) SetMaxResults(v int64) *GetCustomerGatewayAssociationsInput { 4808 s.MaxResults = &v 4809 return s 4810} 4811 4812// SetNextToken sets the NextToken field's value. 4813func (s *GetCustomerGatewayAssociationsInput) SetNextToken(v string) *GetCustomerGatewayAssociationsInput { 4814 s.NextToken = &v 4815 return s 4816} 4817 4818type GetCustomerGatewayAssociationsOutput struct { 4819 _ struct{} `type:"structure"` 4820 4821 // The customer gateway associations. 4822 CustomerGatewayAssociations []*CustomerGatewayAssociation `type:"list"` 4823 4824 // The token for the next page of results. 4825 NextToken *string `type:"string"` 4826} 4827 4828// String returns the string representation 4829func (s GetCustomerGatewayAssociationsOutput) String() string { 4830 return awsutil.Prettify(s) 4831} 4832 4833// GoString returns the string representation 4834func (s GetCustomerGatewayAssociationsOutput) GoString() string { 4835 return s.String() 4836} 4837 4838// SetCustomerGatewayAssociations sets the CustomerGatewayAssociations field's value. 4839func (s *GetCustomerGatewayAssociationsOutput) SetCustomerGatewayAssociations(v []*CustomerGatewayAssociation) *GetCustomerGatewayAssociationsOutput { 4840 s.CustomerGatewayAssociations = v 4841 return s 4842} 4843 4844// SetNextToken sets the NextToken field's value. 4845func (s *GetCustomerGatewayAssociationsOutput) SetNextToken(v string) *GetCustomerGatewayAssociationsOutput { 4846 s.NextToken = &v 4847 return s 4848} 4849 4850type GetDevicesInput struct { 4851 _ struct{} `type:"structure"` 4852 4853 // One or more device IDs. The maximum is 10. 4854 DeviceIds []*string `location:"querystring" locationName:"deviceIds" type:"list"` 4855 4856 // The ID of the global network. 4857 // 4858 // GlobalNetworkId is a required field 4859 GlobalNetworkId *string `location:"uri" locationName:"globalNetworkId" type:"string" required:"true"` 4860 4861 // The maximum number of results to return. 4862 MaxResults *int64 `location:"querystring" locationName:"maxResults" min:"1" type:"integer"` 4863 4864 // The token for the next page of results. 4865 NextToken *string `location:"querystring" locationName:"nextToken" type:"string"` 4866 4867 // The ID of the site. 4868 SiteId *string `location:"querystring" locationName:"siteId" type:"string"` 4869} 4870 4871// String returns the string representation 4872func (s GetDevicesInput) String() string { 4873 return awsutil.Prettify(s) 4874} 4875 4876// GoString returns the string representation 4877func (s GetDevicesInput) GoString() string { 4878 return s.String() 4879} 4880 4881// Validate inspects the fields of the type to determine if they are valid. 4882func (s *GetDevicesInput) Validate() error { 4883 invalidParams := request.ErrInvalidParams{Context: "GetDevicesInput"} 4884 if s.GlobalNetworkId == nil { 4885 invalidParams.Add(request.NewErrParamRequired("GlobalNetworkId")) 4886 } 4887 if s.GlobalNetworkId != nil && len(*s.GlobalNetworkId) < 1 { 4888 invalidParams.Add(request.NewErrParamMinLen("GlobalNetworkId", 1)) 4889 } 4890 if s.MaxResults != nil && *s.MaxResults < 1 { 4891 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 4892 } 4893 4894 if invalidParams.Len() > 0 { 4895 return invalidParams 4896 } 4897 return nil 4898} 4899 4900// SetDeviceIds sets the DeviceIds field's value. 4901func (s *GetDevicesInput) SetDeviceIds(v []*string) *GetDevicesInput { 4902 s.DeviceIds = v 4903 return s 4904} 4905 4906// SetGlobalNetworkId sets the GlobalNetworkId field's value. 4907func (s *GetDevicesInput) SetGlobalNetworkId(v string) *GetDevicesInput { 4908 s.GlobalNetworkId = &v 4909 return s 4910} 4911 4912// SetMaxResults sets the MaxResults field's value. 4913func (s *GetDevicesInput) SetMaxResults(v int64) *GetDevicesInput { 4914 s.MaxResults = &v 4915 return s 4916} 4917 4918// SetNextToken sets the NextToken field's value. 4919func (s *GetDevicesInput) SetNextToken(v string) *GetDevicesInput { 4920 s.NextToken = &v 4921 return s 4922} 4923 4924// SetSiteId sets the SiteId field's value. 4925func (s *GetDevicesInput) SetSiteId(v string) *GetDevicesInput { 4926 s.SiteId = &v 4927 return s 4928} 4929 4930type GetDevicesOutput struct { 4931 _ struct{} `type:"structure"` 4932 4933 // The devices. 4934 Devices []*Device `type:"list"` 4935 4936 // The token for the next page of results. 4937 NextToken *string `type:"string"` 4938} 4939 4940// String returns the string representation 4941func (s GetDevicesOutput) String() string { 4942 return awsutil.Prettify(s) 4943} 4944 4945// GoString returns the string representation 4946func (s GetDevicesOutput) GoString() string { 4947 return s.String() 4948} 4949 4950// SetDevices sets the Devices field's value. 4951func (s *GetDevicesOutput) SetDevices(v []*Device) *GetDevicesOutput { 4952 s.Devices = v 4953 return s 4954} 4955 4956// SetNextToken sets the NextToken field's value. 4957func (s *GetDevicesOutput) SetNextToken(v string) *GetDevicesOutput { 4958 s.NextToken = &v 4959 return s 4960} 4961 4962type GetLinkAssociationsInput struct { 4963 _ struct{} `type:"structure"` 4964 4965 // The ID of the device. 4966 DeviceId *string `location:"querystring" locationName:"deviceId" type:"string"` 4967 4968 // The ID of the global network. 4969 // 4970 // GlobalNetworkId is a required field 4971 GlobalNetworkId *string `location:"uri" locationName:"globalNetworkId" type:"string" required:"true"` 4972 4973 // The ID of the link. 4974 LinkId *string `location:"querystring" locationName:"linkId" type:"string"` 4975 4976 // The maximum number of results to return. 4977 MaxResults *int64 `location:"querystring" locationName:"maxResults" min:"1" type:"integer"` 4978 4979 // The token for the next page of results. 4980 NextToken *string `location:"querystring" locationName:"nextToken" type:"string"` 4981} 4982 4983// String returns the string representation 4984func (s GetLinkAssociationsInput) String() string { 4985 return awsutil.Prettify(s) 4986} 4987 4988// GoString returns the string representation 4989func (s GetLinkAssociationsInput) GoString() string { 4990 return s.String() 4991} 4992 4993// Validate inspects the fields of the type to determine if they are valid. 4994func (s *GetLinkAssociationsInput) Validate() error { 4995 invalidParams := request.ErrInvalidParams{Context: "GetLinkAssociationsInput"} 4996 if s.GlobalNetworkId == nil { 4997 invalidParams.Add(request.NewErrParamRequired("GlobalNetworkId")) 4998 } 4999 if s.GlobalNetworkId != nil && len(*s.GlobalNetworkId) < 1 { 5000 invalidParams.Add(request.NewErrParamMinLen("GlobalNetworkId", 1)) 5001 } 5002 if s.MaxResults != nil && *s.MaxResults < 1 { 5003 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 5004 } 5005 5006 if invalidParams.Len() > 0 { 5007 return invalidParams 5008 } 5009 return nil 5010} 5011 5012// SetDeviceId sets the DeviceId field's value. 5013func (s *GetLinkAssociationsInput) SetDeviceId(v string) *GetLinkAssociationsInput { 5014 s.DeviceId = &v 5015 return s 5016} 5017 5018// SetGlobalNetworkId sets the GlobalNetworkId field's value. 5019func (s *GetLinkAssociationsInput) SetGlobalNetworkId(v string) *GetLinkAssociationsInput { 5020 s.GlobalNetworkId = &v 5021 return s 5022} 5023 5024// SetLinkId sets the LinkId field's value. 5025func (s *GetLinkAssociationsInput) SetLinkId(v string) *GetLinkAssociationsInput { 5026 s.LinkId = &v 5027 return s 5028} 5029 5030// SetMaxResults sets the MaxResults field's value. 5031func (s *GetLinkAssociationsInput) SetMaxResults(v int64) *GetLinkAssociationsInput { 5032 s.MaxResults = &v 5033 return s 5034} 5035 5036// SetNextToken sets the NextToken field's value. 5037func (s *GetLinkAssociationsInput) SetNextToken(v string) *GetLinkAssociationsInput { 5038 s.NextToken = &v 5039 return s 5040} 5041 5042type GetLinkAssociationsOutput struct { 5043 _ struct{} `type:"structure"` 5044 5045 // The link associations. 5046 LinkAssociations []*LinkAssociation `type:"list"` 5047 5048 // The token for the next page of results. 5049 NextToken *string `type:"string"` 5050} 5051 5052// String returns the string representation 5053func (s GetLinkAssociationsOutput) String() string { 5054 return awsutil.Prettify(s) 5055} 5056 5057// GoString returns the string representation 5058func (s GetLinkAssociationsOutput) GoString() string { 5059 return s.String() 5060} 5061 5062// SetLinkAssociations sets the LinkAssociations field's value. 5063func (s *GetLinkAssociationsOutput) SetLinkAssociations(v []*LinkAssociation) *GetLinkAssociationsOutput { 5064 s.LinkAssociations = v 5065 return s 5066} 5067 5068// SetNextToken sets the NextToken field's value. 5069func (s *GetLinkAssociationsOutput) SetNextToken(v string) *GetLinkAssociationsOutput { 5070 s.NextToken = &v 5071 return s 5072} 5073 5074type GetLinksInput struct { 5075 _ struct{} `type:"structure"` 5076 5077 // The ID of the global network. 5078 // 5079 // GlobalNetworkId is a required field 5080 GlobalNetworkId *string `location:"uri" locationName:"globalNetworkId" type:"string" required:"true"` 5081 5082 // One or more link IDs. The maximum is 10. 5083 LinkIds []*string `location:"querystring" locationName:"linkIds" type:"list"` 5084 5085 // The maximum number of results to return. 5086 MaxResults *int64 `location:"querystring" locationName:"maxResults" min:"1" type:"integer"` 5087 5088 // The token for the next page of results. 5089 NextToken *string `location:"querystring" locationName:"nextToken" type:"string"` 5090 5091 // The link provider. 5092 Provider *string `location:"querystring" locationName:"provider" type:"string"` 5093 5094 // The ID of the site. 5095 SiteId *string `location:"querystring" locationName:"siteId" type:"string"` 5096 5097 // The link type. 5098 Type *string `location:"querystring" locationName:"type" type:"string"` 5099} 5100 5101// String returns the string representation 5102func (s GetLinksInput) String() string { 5103 return awsutil.Prettify(s) 5104} 5105 5106// GoString returns the string representation 5107func (s GetLinksInput) GoString() string { 5108 return s.String() 5109} 5110 5111// Validate inspects the fields of the type to determine if they are valid. 5112func (s *GetLinksInput) Validate() error { 5113 invalidParams := request.ErrInvalidParams{Context: "GetLinksInput"} 5114 if s.GlobalNetworkId == nil { 5115 invalidParams.Add(request.NewErrParamRequired("GlobalNetworkId")) 5116 } 5117 if s.GlobalNetworkId != nil && len(*s.GlobalNetworkId) < 1 { 5118 invalidParams.Add(request.NewErrParamMinLen("GlobalNetworkId", 1)) 5119 } 5120 if s.MaxResults != nil && *s.MaxResults < 1 { 5121 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 5122 } 5123 5124 if invalidParams.Len() > 0 { 5125 return invalidParams 5126 } 5127 return nil 5128} 5129 5130// SetGlobalNetworkId sets the GlobalNetworkId field's value. 5131func (s *GetLinksInput) SetGlobalNetworkId(v string) *GetLinksInput { 5132 s.GlobalNetworkId = &v 5133 return s 5134} 5135 5136// SetLinkIds sets the LinkIds field's value. 5137func (s *GetLinksInput) SetLinkIds(v []*string) *GetLinksInput { 5138 s.LinkIds = v 5139 return s 5140} 5141 5142// SetMaxResults sets the MaxResults field's value. 5143func (s *GetLinksInput) SetMaxResults(v int64) *GetLinksInput { 5144 s.MaxResults = &v 5145 return s 5146} 5147 5148// SetNextToken sets the NextToken field's value. 5149func (s *GetLinksInput) SetNextToken(v string) *GetLinksInput { 5150 s.NextToken = &v 5151 return s 5152} 5153 5154// SetProvider sets the Provider field's value. 5155func (s *GetLinksInput) SetProvider(v string) *GetLinksInput { 5156 s.Provider = &v 5157 return s 5158} 5159 5160// SetSiteId sets the SiteId field's value. 5161func (s *GetLinksInput) SetSiteId(v string) *GetLinksInput { 5162 s.SiteId = &v 5163 return s 5164} 5165 5166// SetType sets the Type field's value. 5167func (s *GetLinksInput) SetType(v string) *GetLinksInput { 5168 s.Type = &v 5169 return s 5170} 5171 5172type GetLinksOutput struct { 5173 _ struct{} `type:"structure"` 5174 5175 // The links. 5176 Links []*Link `type:"list"` 5177 5178 // The token for the next page of results. 5179 NextToken *string `type:"string"` 5180} 5181 5182// String returns the string representation 5183func (s GetLinksOutput) String() string { 5184 return awsutil.Prettify(s) 5185} 5186 5187// GoString returns the string representation 5188func (s GetLinksOutput) GoString() string { 5189 return s.String() 5190} 5191 5192// SetLinks sets the Links field's value. 5193func (s *GetLinksOutput) SetLinks(v []*Link) *GetLinksOutput { 5194 s.Links = v 5195 return s 5196} 5197 5198// SetNextToken sets the NextToken field's value. 5199func (s *GetLinksOutput) SetNextToken(v string) *GetLinksOutput { 5200 s.NextToken = &v 5201 return s 5202} 5203 5204type GetSitesInput struct { 5205 _ struct{} `type:"structure"` 5206 5207 // The ID of the global network. 5208 // 5209 // GlobalNetworkId is a required field 5210 GlobalNetworkId *string `location:"uri" locationName:"globalNetworkId" type:"string" required:"true"` 5211 5212 // The maximum number of results to return. 5213 MaxResults *int64 `location:"querystring" locationName:"maxResults" min:"1" type:"integer"` 5214 5215 // The token for the next page of results. 5216 NextToken *string `location:"querystring" locationName:"nextToken" type:"string"` 5217 5218 // One or more site IDs. The maximum is 10. 5219 SiteIds []*string `location:"querystring" locationName:"siteIds" type:"list"` 5220} 5221 5222// String returns the string representation 5223func (s GetSitesInput) String() string { 5224 return awsutil.Prettify(s) 5225} 5226 5227// GoString returns the string representation 5228func (s GetSitesInput) GoString() string { 5229 return s.String() 5230} 5231 5232// Validate inspects the fields of the type to determine if they are valid. 5233func (s *GetSitesInput) Validate() error { 5234 invalidParams := request.ErrInvalidParams{Context: "GetSitesInput"} 5235 if s.GlobalNetworkId == nil { 5236 invalidParams.Add(request.NewErrParamRequired("GlobalNetworkId")) 5237 } 5238 if s.GlobalNetworkId != nil && len(*s.GlobalNetworkId) < 1 { 5239 invalidParams.Add(request.NewErrParamMinLen("GlobalNetworkId", 1)) 5240 } 5241 if s.MaxResults != nil && *s.MaxResults < 1 { 5242 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 5243 } 5244 5245 if invalidParams.Len() > 0 { 5246 return invalidParams 5247 } 5248 return nil 5249} 5250 5251// SetGlobalNetworkId sets the GlobalNetworkId field's value. 5252func (s *GetSitesInput) SetGlobalNetworkId(v string) *GetSitesInput { 5253 s.GlobalNetworkId = &v 5254 return s 5255} 5256 5257// SetMaxResults sets the MaxResults field's value. 5258func (s *GetSitesInput) SetMaxResults(v int64) *GetSitesInput { 5259 s.MaxResults = &v 5260 return s 5261} 5262 5263// SetNextToken sets the NextToken field's value. 5264func (s *GetSitesInput) SetNextToken(v string) *GetSitesInput { 5265 s.NextToken = &v 5266 return s 5267} 5268 5269// SetSiteIds sets the SiteIds field's value. 5270func (s *GetSitesInput) SetSiteIds(v []*string) *GetSitesInput { 5271 s.SiteIds = v 5272 return s 5273} 5274 5275type GetSitesOutput struct { 5276 _ struct{} `type:"structure"` 5277 5278 // The token for the next page of results. 5279 NextToken *string `type:"string"` 5280 5281 // The sites. 5282 Sites []*Site `type:"list"` 5283} 5284 5285// String returns the string representation 5286func (s GetSitesOutput) String() string { 5287 return awsutil.Prettify(s) 5288} 5289 5290// GoString returns the string representation 5291func (s GetSitesOutput) GoString() string { 5292 return s.String() 5293} 5294 5295// SetNextToken sets the NextToken field's value. 5296func (s *GetSitesOutput) SetNextToken(v string) *GetSitesOutput { 5297 s.NextToken = &v 5298 return s 5299} 5300 5301// SetSites sets the Sites field's value. 5302func (s *GetSitesOutput) SetSites(v []*Site) *GetSitesOutput { 5303 s.Sites = v 5304 return s 5305} 5306 5307type GetTransitGatewayRegistrationsInput struct { 5308 _ struct{} `type:"structure"` 5309 5310 // The ID of the global network. 5311 // 5312 // GlobalNetworkId is a required field 5313 GlobalNetworkId *string `location:"uri" locationName:"globalNetworkId" type:"string" required:"true"` 5314 5315 // The maximum number of results to return. 5316 MaxResults *int64 `location:"querystring" locationName:"maxResults" min:"1" type:"integer"` 5317 5318 // The token for the next page of results. 5319 NextToken *string `location:"querystring" locationName:"nextToken" type:"string"` 5320 5321 // The Amazon Resource Names (ARNs) of one or more transit gateways. The maximum 5322 // is 10. 5323 TransitGatewayArns []*string `location:"querystring" locationName:"transitGatewayArns" type:"list"` 5324} 5325 5326// String returns the string representation 5327func (s GetTransitGatewayRegistrationsInput) String() string { 5328 return awsutil.Prettify(s) 5329} 5330 5331// GoString returns the string representation 5332func (s GetTransitGatewayRegistrationsInput) GoString() string { 5333 return s.String() 5334} 5335 5336// Validate inspects the fields of the type to determine if they are valid. 5337func (s *GetTransitGatewayRegistrationsInput) Validate() error { 5338 invalidParams := request.ErrInvalidParams{Context: "GetTransitGatewayRegistrationsInput"} 5339 if s.GlobalNetworkId == nil { 5340 invalidParams.Add(request.NewErrParamRequired("GlobalNetworkId")) 5341 } 5342 if s.GlobalNetworkId != nil && len(*s.GlobalNetworkId) < 1 { 5343 invalidParams.Add(request.NewErrParamMinLen("GlobalNetworkId", 1)) 5344 } 5345 if s.MaxResults != nil && *s.MaxResults < 1 { 5346 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 5347 } 5348 5349 if invalidParams.Len() > 0 { 5350 return invalidParams 5351 } 5352 return nil 5353} 5354 5355// SetGlobalNetworkId sets the GlobalNetworkId field's value. 5356func (s *GetTransitGatewayRegistrationsInput) SetGlobalNetworkId(v string) *GetTransitGatewayRegistrationsInput { 5357 s.GlobalNetworkId = &v 5358 return s 5359} 5360 5361// SetMaxResults sets the MaxResults field's value. 5362func (s *GetTransitGatewayRegistrationsInput) SetMaxResults(v int64) *GetTransitGatewayRegistrationsInput { 5363 s.MaxResults = &v 5364 return s 5365} 5366 5367// SetNextToken sets the NextToken field's value. 5368func (s *GetTransitGatewayRegistrationsInput) SetNextToken(v string) *GetTransitGatewayRegistrationsInput { 5369 s.NextToken = &v 5370 return s 5371} 5372 5373// SetTransitGatewayArns sets the TransitGatewayArns field's value. 5374func (s *GetTransitGatewayRegistrationsInput) SetTransitGatewayArns(v []*string) *GetTransitGatewayRegistrationsInput { 5375 s.TransitGatewayArns = v 5376 return s 5377} 5378 5379type GetTransitGatewayRegistrationsOutput struct { 5380 _ struct{} `type:"structure"` 5381 5382 // The token for the next page of results. 5383 NextToken *string `type:"string"` 5384 5385 // The transit gateway registrations. 5386 TransitGatewayRegistrations []*TransitGatewayRegistration `type:"list"` 5387} 5388 5389// String returns the string representation 5390func (s GetTransitGatewayRegistrationsOutput) String() string { 5391 return awsutil.Prettify(s) 5392} 5393 5394// GoString returns the string representation 5395func (s GetTransitGatewayRegistrationsOutput) GoString() string { 5396 return s.String() 5397} 5398 5399// SetNextToken sets the NextToken field's value. 5400func (s *GetTransitGatewayRegistrationsOutput) SetNextToken(v string) *GetTransitGatewayRegistrationsOutput { 5401 s.NextToken = &v 5402 return s 5403} 5404 5405// SetTransitGatewayRegistrations sets the TransitGatewayRegistrations field's value. 5406func (s *GetTransitGatewayRegistrationsOutput) SetTransitGatewayRegistrations(v []*TransitGatewayRegistration) *GetTransitGatewayRegistrationsOutput { 5407 s.TransitGatewayRegistrations = v 5408 return s 5409} 5410 5411// Describes a global network. 5412type GlobalNetwork struct { 5413 _ struct{} `type:"structure"` 5414 5415 // The date and time that the global network was created. 5416 CreatedAt *time.Time `type:"timestamp"` 5417 5418 // The description of the global network. 5419 Description *string `type:"string"` 5420 5421 // The Amazon Resource Name (ARN) of the global network. 5422 GlobalNetworkArn *string `type:"string"` 5423 5424 // The ID of the global network. 5425 GlobalNetworkId *string `type:"string"` 5426 5427 // The state of the global network. 5428 State *string `type:"string" enum:"GlobalNetworkState"` 5429 5430 // The tags for the global network. 5431 Tags []*Tag `type:"list"` 5432} 5433 5434// String returns the string representation 5435func (s GlobalNetwork) String() string { 5436 return awsutil.Prettify(s) 5437} 5438 5439// GoString returns the string representation 5440func (s GlobalNetwork) GoString() string { 5441 return s.String() 5442} 5443 5444// SetCreatedAt sets the CreatedAt field's value. 5445func (s *GlobalNetwork) SetCreatedAt(v time.Time) *GlobalNetwork { 5446 s.CreatedAt = &v 5447 return s 5448} 5449 5450// SetDescription sets the Description field's value. 5451func (s *GlobalNetwork) SetDescription(v string) *GlobalNetwork { 5452 s.Description = &v 5453 return s 5454} 5455 5456// SetGlobalNetworkArn sets the GlobalNetworkArn field's value. 5457func (s *GlobalNetwork) SetGlobalNetworkArn(v string) *GlobalNetwork { 5458 s.GlobalNetworkArn = &v 5459 return s 5460} 5461 5462// SetGlobalNetworkId sets the GlobalNetworkId field's value. 5463func (s *GlobalNetwork) SetGlobalNetworkId(v string) *GlobalNetwork { 5464 s.GlobalNetworkId = &v 5465 return s 5466} 5467 5468// SetState sets the State field's value. 5469func (s *GlobalNetwork) SetState(v string) *GlobalNetwork { 5470 s.State = &v 5471 return s 5472} 5473 5474// SetTags sets the Tags field's value. 5475func (s *GlobalNetwork) SetTags(v []*Tag) *GlobalNetwork { 5476 s.Tags = v 5477 return s 5478} 5479 5480// The request has failed due to an internal error. 5481type InternalServerException struct { 5482 _ struct{} `type:"structure"` 5483 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 5484 5485 Message_ *string `locationName:"Message" type:"string"` 5486 5487 // Indicates when to retry the request. 5488 RetryAfterSeconds *int64 `location:"header" locationName:"Retry-After" type:"integer"` 5489} 5490 5491// String returns the string representation 5492func (s InternalServerException) String() string { 5493 return awsutil.Prettify(s) 5494} 5495 5496// GoString returns the string representation 5497func (s InternalServerException) GoString() string { 5498 return s.String() 5499} 5500 5501func newErrorInternalServerException(v protocol.ResponseMetadata) error { 5502 return &InternalServerException{ 5503 RespMetadata: v, 5504 } 5505} 5506 5507// Code returns the exception type name. 5508func (s *InternalServerException) Code() string { 5509 return "InternalServerException" 5510} 5511 5512// Message returns the exception's message. 5513func (s *InternalServerException) Message() string { 5514 if s.Message_ != nil { 5515 return *s.Message_ 5516 } 5517 return "" 5518} 5519 5520// OrigErr always returns nil, satisfies awserr.Error interface. 5521func (s *InternalServerException) OrigErr() error { 5522 return nil 5523} 5524 5525func (s *InternalServerException) Error() string { 5526 return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) 5527} 5528 5529// Status code returns the HTTP status code for the request's response error. 5530func (s *InternalServerException) StatusCode() int { 5531 return s.RespMetadata.StatusCode 5532} 5533 5534// RequestID returns the service's response RequestID for request. 5535func (s *InternalServerException) RequestID() string { 5536 return s.RespMetadata.RequestID 5537} 5538 5539// Describes a link. 5540type Link struct { 5541 _ struct{} `type:"structure"` 5542 5543 // The bandwidth for the link. 5544 Bandwidth *Bandwidth `type:"structure"` 5545 5546 // The date and time that the link was created. 5547 CreatedAt *time.Time `type:"timestamp"` 5548 5549 // The description of the link. 5550 Description *string `type:"string"` 5551 5552 // The ID of the global network. 5553 GlobalNetworkId *string `type:"string"` 5554 5555 // The Amazon Resource Name (ARN) of the link. 5556 LinkArn *string `type:"string"` 5557 5558 // The ID of the link. 5559 LinkId *string `type:"string"` 5560 5561 // The provider of the link. 5562 Provider *string `type:"string"` 5563 5564 // The ID of the site. 5565 SiteId *string `type:"string"` 5566 5567 // The state of the link. 5568 State *string `type:"string" enum:"LinkState"` 5569 5570 // The tags for the link. 5571 Tags []*Tag `type:"list"` 5572 5573 // The type of the link. 5574 Type *string `type:"string"` 5575} 5576 5577// String returns the string representation 5578func (s Link) String() string { 5579 return awsutil.Prettify(s) 5580} 5581 5582// GoString returns the string representation 5583func (s Link) GoString() string { 5584 return s.String() 5585} 5586 5587// SetBandwidth sets the Bandwidth field's value. 5588func (s *Link) SetBandwidth(v *Bandwidth) *Link { 5589 s.Bandwidth = v 5590 return s 5591} 5592 5593// SetCreatedAt sets the CreatedAt field's value. 5594func (s *Link) SetCreatedAt(v time.Time) *Link { 5595 s.CreatedAt = &v 5596 return s 5597} 5598 5599// SetDescription sets the Description field's value. 5600func (s *Link) SetDescription(v string) *Link { 5601 s.Description = &v 5602 return s 5603} 5604 5605// SetGlobalNetworkId sets the GlobalNetworkId field's value. 5606func (s *Link) SetGlobalNetworkId(v string) *Link { 5607 s.GlobalNetworkId = &v 5608 return s 5609} 5610 5611// SetLinkArn sets the LinkArn field's value. 5612func (s *Link) SetLinkArn(v string) *Link { 5613 s.LinkArn = &v 5614 return s 5615} 5616 5617// SetLinkId sets the LinkId field's value. 5618func (s *Link) SetLinkId(v string) *Link { 5619 s.LinkId = &v 5620 return s 5621} 5622 5623// SetProvider sets the Provider field's value. 5624func (s *Link) SetProvider(v string) *Link { 5625 s.Provider = &v 5626 return s 5627} 5628 5629// SetSiteId sets the SiteId field's value. 5630func (s *Link) SetSiteId(v string) *Link { 5631 s.SiteId = &v 5632 return s 5633} 5634 5635// SetState sets the State field's value. 5636func (s *Link) SetState(v string) *Link { 5637 s.State = &v 5638 return s 5639} 5640 5641// SetTags sets the Tags field's value. 5642func (s *Link) SetTags(v []*Tag) *Link { 5643 s.Tags = v 5644 return s 5645} 5646 5647// SetType sets the Type field's value. 5648func (s *Link) SetType(v string) *Link { 5649 s.Type = &v 5650 return s 5651} 5652 5653// Describes the association between a device and a link. 5654type LinkAssociation struct { 5655 _ struct{} `type:"structure"` 5656 5657 // The device ID for the link association. 5658 DeviceId *string `type:"string"` 5659 5660 // The ID of the global network. 5661 GlobalNetworkId *string `type:"string"` 5662 5663 // The state of the association. 5664 LinkAssociationState *string `type:"string" enum:"LinkAssociationState"` 5665 5666 // The ID of the link. 5667 LinkId *string `type:"string"` 5668} 5669 5670// String returns the string representation 5671func (s LinkAssociation) String() string { 5672 return awsutil.Prettify(s) 5673} 5674 5675// GoString returns the string representation 5676func (s LinkAssociation) GoString() string { 5677 return s.String() 5678} 5679 5680// SetDeviceId sets the DeviceId field's value. 5681func (s *LinkAssociation) SetDeviceId(v string) *LinkAssociation { 5682 s.DeviceId = &v 5683 return s 5684} 5685 5686// SetGlobalNetworkId sets the GlobalNetworkId field's value. 5687func (s *LinkAssociation) SetGlobalNetworkId(v string) *LinkAssociation { 5688 s.GlobalNetworkId = &v 5689 return s 5690} 5691 5692// SetLinkAssociationState sets the LinkAssociationState field's value. 5693func (s *LinkAssociation) SetLinkAssociationState(v string) *LinkAssociation { 5694 s.LinkAssociationState = &v 5695 return s 5696} 5697 5698// SetLinkId sets the LinkId field's value. 5699func (s *LinkAssociation) SetLinkId(v string) *LinkAssociation { 5700 s.LinkId = &v 5701 return s 5702} 5703 5704type ListTagsForResourceInput struct { 5705 _ struct{} `type:"structure"` 5706 5707 // The Amazon Resource Name (ARN) of the resource. 5708 // 5709 // ResourceArn is a required field 5710 ResourceArn *string `location:"uri" locationName:"resourceArn" type:"string" required:"true"` 5711} 5712 5713// String returns the string representation 5714func (s ListTagsForResourceInput) String() string { 5715 return awsutil.Prettify(s) 5716} 5717 5718// GoString returns the string representation 5719func (s ListTagsForResourceInput) GoString() string { 5720 return s.String() 5721} 5722 5723// Validate inspects the fields of the type to determine if they are valid. 5724func (s *ListTagsForResourceInput) Validate() error { 5725 invalidParams := request.ErrInvalidParams{Context: "ListTagsForResourceInput"} 5726 if s.ResourceArn == nil { 5727 invalidParams.Add(request.NewErrParamRequired("ResourceArn")) 5728 } 5729 if s.ResourceArn != nil && len(*s.ResourceArn) < 1 { 5730 invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 1)) 5731 } 5732 5733 if invalidParams.Len() > 0 { 5734 return invalidParams 5735 } 5736 return nil 5737} 5738 5739// SetResourceArn sets the ResourceArn field's value. 5740func (s *ListTagsForResourceInput) SetResourceArn(v string) *ListTagsForResourceInput { 5741 s.ResourceArn = &v 5742 return s 5743} 5744 5745type ListTagsForResourceOutput struct { 5746 _ struct{} `type:"structure"` 5747 5748 // The list of tags. 5749 TagList []*Tag `type:"list"` 5750} 5751 5752// String returns the string representation 5753func (s ListTagsForResourceOutput) String() string { 5754 return awsutil.Prettify(s) 5755} 5756 5757// GoString returns the string representation 5758func (s ListTagsForResourceOutput) GoString() string { 5759 return s.String() 5760} 5761 5762// SetTagList sets the TagList field's value. 5763func (s *ListTagsForResourceOutput) SetTagList(v []*Tag) *ListTagsForResourceOutput { 5764 s.TagList = v 5765 return s 5766} 5767 5768// Describes a location. 5769type Location struct { 5770 _ struct{} `type:"structure"` 5771 5772 // The physical address. 5773 Address *string `type:"string"` 5774 5775 // The latitude. 5776 Latitude *string `type:"string"` 5777 5778 // The longitude. 5779 Longitude *string `type:"string"` 5780} 5781 5782// String returns the string representation 5783func (s Location) String() string { 5784 return awsutil.Prettify(s) 5785} 5786 5787// GoString returns the string representation 5788func (s Location) GoString() string { 5789 return s.String() 5790} 5791 5792// SetAddress sets the Address field's value. 5793func (s *Location) SetAddress(v string) *Location { 5794 s.Address = &v 5795 return s 5796} 5797 5798// SetLatitude sets the Latitude field's value. 5799func (s *Location) SetLatitude(v string) *Location { 5800 s.Latitude = &v 5801 return s 5802} 5803 5804// SetLongitude sets the Longitude field's value. 5805func (s *Location) SetLongitude(v string) *Location { 5806 s.Longitude = &v 5807 return s 5808} 5809 5810type RegisterTransitGatewayInput struct { 5811 _ struct{} `type:"structure"` 5812 5813 // The ID of the global network. 5814 // 5815 // GlobalNetworkId is a required field 5816 GlobalNetworkId *string `location:"uri" locationName:"globalNetworkId" type:"string" required:"true"` 5817 5818 // The Amazon Resource Name (ARN) of the transit gateway. For more information, 5819 // see Resources Defined by Amazon EC2 (https://docs.aws.amazon.com/IAM/latest/UserGuide/list_amazonec2.html#amazonec2-resources-for-iam-policies). 5820 // 5821 // TransitGatewayArn is a required field 5822 TransitGatewayArn *string `type:"string" required:"true"` 5823} 5824 5825// String returns the string representation 5826func (s RegisterTransitGatewayInput) String() string { 5827 return awsutil.Prettify(s) 5828} 5829 5830// GoString returns the string representation 5831func (s RegisterTransitGatewayInput) GoString() string { 5832 return s.String() 5833} 5834 5835// Validate inspects the fields of the type to determine if they are valid. 5836func (s *RegisterTransitGatewayInput) Validate() error { 5837 invalidParams := request.ErrInvalidParams{Context: "RegisterTransitGatewayInput"} 5838 if s.GlobalNetworkId == nil { 5839 invalidParams.Add(request.NewErrParamRequired("GlobalNetworkId")) 5840 } 5841 if s.GlobalNetworkId != nil && len(*s.GlobalNetworkId) < 1 { 5842 invalidParams.Add(request.NewErrParamMinLen("GlobalNetworkId", 1)) 5843 } 5844 if s.TransitGatewayArn == nil { 5845 invalidParams.Add(request.NewErrParamRequired("TransitGatewayArn")) 5846 } 5847 5848 if invalidParams.Len() > 0 { 5849 return invalidParams 5850 } 5851 return nil 5852} 5853 5854// SetGlobalNetworkId sets the GlobalNetworkId field's value. 5855func (s *RegisterTransitGatewayInput) SetGlobalNetworkId(v string) *RegisterTransitGatewayInput { 5856 s.GlobalNetworkId = &v 5857 return s 5858} 5859 5860// SetTransitGatewayArn sets the TransitGatewayArn field's value. 5861func (s *RegisterTransitGatewayInput) SetTransitGatewayArn(v string) *RegisterTransitGatewayInput { 5862 s.TransitGatewayArn = &v 5863 return s 5864} 5865 5866type RegisterTransitGatewayOutput struct { 5867 _ struct{} `type:"structure"` 5868 5869 // Information about the transit gateway registration. 5870 TransitGatewayRegistration *TransitGatewayRegistration `type:"structure"` 5871} 5872 5873// String returns the string representation 5874func (s RegisterTransitGatewayOutput) String() string { 5875 return awsutil.Prettify(s) 5876} 5877 5878// GoString returns the string representation 5879func (s RegisterTransitGatewayOutput) GoString() string { 5880 return s.String() 5881} 5882 5883// SetTransitGatewayRegistration sets the TransitGatewayRegistration field's value. 5884func (s *RegisterTransitGatewayOutput) SetTransitGatewayRegistration(v *TransitGatewayRegistration) *RegisterTransitGatewayOutput { 5885 s.TransitGatewayRegistration = v 5886 return s 5887} 5888 5889// The specified resource could not be found. 5890type ResourceNotFoundException struct { 5891 _ struct{} `type:"structure"` 5892 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 5893 5894 Message_ *string `locationName:"Message" type:"string"` 5895 5896 // The ID of the resource. 5897 // 5898 // ResourceId is a required field 5899 ResourceId *string `type:"string" required:"true"` 5900 5901 // The resource type. 5902 // 5903 // ResourceType is a required field 5904 ResourceType *string `type:"string" required:"true"` 5905} 5906 5907// String returns the string representation 5908func (s ResourceNotFoundException) String() string { 5909 return awsutil.Prettify(s) 5910} 5911 5912// GoString returns the string representation 5913func (s ResourceNotFoundException) GoString() string { 5914 return s.String() 5915} 5916 5917func newErrorResourceNotFoundException(v protocol.ResponseMetadata) error { 5918 return &ResourceNotFoundException{ 5919 RespMetadata: v, 5920 } 5921} 5922 5923// Code returns the exception type name. 5924func (s *ResourceNotFoundException) Code() string { 5925 return "ResourceNotFoundException" 5926} 5927 5928// Message returns the exception's message. 5929func (s *ResourceNotFoundException) Message() string { 5930 if s.Message_ != nil { 5931 return *s.Message_ 5932 } 5933 return "" 5934} 5935 5936// OrigErr always returns nil, satisfies awserr.Error interface. 5937func (s *ResourceNotFoundException) OrigErr() error { 5938 return nil 5939} 5940 5941func (s *ResourceNotFoundException) Error() string { 5942 return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) 5943} 5944 5945// Status code returns the HTTP status code for the request's response error. 5946func (s *ResourceNotFoundException) StatusCode() int { 5947 return s.RespMetadata.StatusCode 5948} 5949 5950// RequestID returns the service's response RequestID for request. 5951func (s *ResourceNotFoundException) RequestID() string { 5952 return s.RespMetadata.RequestID 5953} 5954 5955// A service limit was exceeded. 5956type ServiceQuotaExceededException struct { 5957 _ struct{} `type:"structure"` 5958 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 5959 5960 // The limit code. 5961 // 5962 // LimitCode is a required field 5963 LimitCode *string `type:"string" required:"true"` 5964 5965 // The error message. 5966 Message_ *string `locationName:"Message" type:"string"` 5967 5968 // The ID of the resource. 5969 ResourceId *string `type:"string"` 5970 5971 // The resource type. 5972 ResourceType *string `type:"string"` 5973 5974 // The service code. 5975 // 5976 // ServiceCode is a required field 5977 ServiceCode *string `type:"string" required:"true"` 5978} 5979 5980// String returns the string representation 5981func (s ServiceQuotaExceededException) String() string { 5982 return awsutil.Prettify(s) 5983} 5984 5985// GoString returns the string representation 5986func (s ServiceQuotaExceededException) GoString() string { 5987 return s.String() 5988} 5989 5990func newErrorServiceQuotaExceededException(v protocol.ResponseMetadata) error { 5991 return &ServiceQuotaExceededException{ 5992 RespMetadata: v, 5993 } 5994} 5995 5996// Code returns the exception type name. 5997func (s *ServiceQuotaExceededException) Code() string { 5998 return "ServiceQuotaExceededException" 5999} 6000 6001// Message returns the exception's message. 6002func (s *ServiceQuotaExceededException) Message() string { 6003 if s.Message_ != nil { 6004 return *s.Message_ 6005 } 6006 return "" 6007} 6008 6009// OrigErr always returns nil, satisfies awserr.Error interface. 6010func (s *ServiceQuotaExceededException) OrigErr() error { 6011 return nil 6012} 6013 6014func (s *ServiceQuotaExceededException) Error() string { 6015 return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) 6016} 6017 6018// Status code returns the HTTP status code for the request's response error. 6019func (s *ServiceQuotaExceededException) StatusCode() int { 6020 return s.RespMetadata.StatusCode 6021} 6022 6023// RequestID returns the service's response RequestID for request. 6024func (s *ServiceQuotaExceededException) RequestID() string { 6025 return s.RespMetadata.RequestID 6026} 6027 6028// Describes a site. 6029type Site struct { 6030 _ struct{} `type:"structure"` 6031 6032 // The date and time that the site was created. 6033 CreatedAt *time.Time `type:"timestamp"` 6034 6035 // The description of the site. 6036 Description *string `type:"string"` 6037 6038 // The ID of the global network. 6039 GlobalNetworkId *string `type:"string"` 6040 6041 // The location of the site. 6042 Location *Location `type:"structure"` 6043 6044 // The Amazon Resource Name (ARN) of the site. 6045 SiteArn *string `type:"string"` 6046 6047 // The ID of the site. 6048 SiteId *string `type:"string"` 6049 6050 // The state of the site. 6051 State *string `type:"string" enum:"SiteState"` 6052 6053 // The tags for the site. 6054 Tags []*Tag `type:"list"` 6055} 6056 6057// String returns the string representation 6058func (s Site) String() string { 6059 return awsutil.Prettify(s) 6060} 6061 6062// GoString returns the string representation 6063func (s Site) GoString() string { 6064 return s.String() 6065} 6066 6067// SetCreatedAt sets the CreatedAt field's value. 6068func (s *Site) SetCreatedAt(v time.Time) *Site { 6069 s.CreatedAt = &v 6070 return s 6071} 6072 6073// SetDescription sets the Description field's value. 6074func (s *Site) SetDescription(v string) *Site { 6075 s.Description = &v 6076 return s 6077} 6078 6079// SetGlobalNetworkId sets the GlobalNetworkId field's value. 6080func (s *Site) SetGlobalNetworkId(v string) *Site { 6081 s.GlobalNetworkId = &v 6082 return s 6083} 6084 6085// SetLocation sets the Location field's value. 6086func (s *Site) SetLocation(v *Location) *Site { 6087 s.Location = v 6088 return s 6089} 6090 6091// SetSiteArn sets the SiteArn field's value. 6092func (s *Site) SetSiteArn(v string) *Site { 6093 s.SiteArn = &v 6094 return s 6095} 6096 6097// SetSiteId sets the SiteId field's value. 6098func (s *Site) SetSiteId(v string) *Site { 6099 s.SiteId = &v 6100 return s 6101} 6102 6103// SetState sets the State field's value. 6104func (s *Site) SetState(v string) *Site { 6105 s.State = &v 6106 return s 6107} 6108 6109// SetTags sets the Tags field's value. 6110func (s *Site) SetTags(v []*Tag) *Site { 6111 s.Tags = v 6112 return s 6113} 6114 6115// Describes a tag. 6116type Tag struct { 6117 _ struct{} `type:"structure"` 6118 6119 // The tag key. 6120 // 6121 // Length Constraints: Maximum length of 128 characters. 6122 Key *string `type:"string"` 6123 6124 // The tag value. 6125 // 6126 // Length Constraints: Maximum length of 256 characters. 6127 Value *string `type:"string"` 6128} 6129 6130// String returns the string representation 6131func (s Tag) String() string { 6132 return awsutil.Prettify(s) 6133} 6134 6135// GoString returns the string representation 6136func (s Tag) GoString() string { 6137 return s.String() 6138} 6139 6140// SetKey sets the Key field's value. 6141func (s *Tag) SetKey(v string) *Tag { 6142 s.Key = &v 6143 return s 6144} 6145 6146// SetValue sets the Value field's value. 6147func (s *Tag) SetValue(v string) *Tag { 6148 s.Value = &v 6149 return s 6150} 6151 6152type TagResourceInput struct { 6153 _ struct{} `type:"structure"` 6154 6155 // The Amazon Resource Name (ARN) of the resource. 6156 // 6157 // ResourceArn is a required field 6158 ResourceArn *string `location:"uri" locationName:"resourceArn" type:"string" required:"true"` 6159 6160 // The tags to apply to the specified resource. 6161 // 6162 // Tags is a required field 6163 Tags []*Tag `type:"list" required:"true"` 6164} 6165 6166// String returns the string representation 6167func (s TagResourceInput) String() string { 6168 return awsutil.Prettify(s) 6169} 6170 6171// GoString returns the string representation 6172func (s TagResourceInput) GoString() string { 6173 return s.String() 6174} 6175 6176// Validate inspects the fields of the type to determine if they are valid. 6177func (s *TagResourceInput) Validate() error { 6178 invalidParams := request.ErrInvalidParams{Context: "TagResourceInput"} 6179 if s.ResourceArn == nil { 6180 invalidParams.Add(request.NewErrParamRequired("ResourceArn")) 6181 } 6182 if s.ResourceArn != nil && len(*s.ResourceArn) < 1 { 6183 invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 1)) 6184 } 6185 if s.Tags == nil { 6186 invalidParams.Add(request.NewErrParamRequired("Tags")) 6187 } 6188 6189 if invalidParams.Len() > 0 { 6190 return invalidParams 6191 } 6192 return nil 6193} 6194 6195// SetResourceArn sets the ResourceArn field's value. 6196func (s *TagResourceInput) SetResourceArn(v string) *TagResourceInput { 6197 s.ResourceArn = &v 6198 return s 6199} 6200 6201// SetTags sets the Tags field's value. 6202func (s *TagResourceInput) SetTags(v []*Tag) *TagResourceInput { 6203 s.Tags = v 6204 return s 6205} 6206 6207type TagResourceOutput struct { 6208 _ struct{} `type:"structure"` 6209} 6210 6211// String returns the string representation 6212func (s TagResourceOutput) String() string { 6213 return awsutil.Prettify(s) 6214} 6215 6216// GoString returns the string representation 6217func (s TagResourceOutput) GoString() string { 6218 return s.String() 6219} 6220 6221// The request was denied due to request throttling. 6222type ThrottlingException struct { 6223 _ struct{} `type:"structure"` 6224 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 6225 6226 Message_ *string `locationName:"Message" type:"string"` 6227 6228 // Indicates when to retry the request. 6229 RetryAfterSeconds *int64 `location:"header" locationName:"Retry-After" type:"integer"` 6230} 6231 6232// String returns the string representation 6233func (s ThrottlingException) String() string { 6234 return awsutil.Prettify(s) 6235} 6236 6237// GoString returns the string representation 6238func (s ThrottlingException) GoString() string { 6239 return s.String() 6240} 6241 6242func newErrorThrottlingException(v protocol.ResponseMetadata) error { 6243 return &ThrottlingException{ 6244 RespMetadata: v, 6245 } 6246} 6247 6248// Code returns the exception type name. 6249func (s *ThrottlingException) Code() string { 6250 return "ThrottlingException" 6251} 6252 6253// Message returns the exception's message. 6254func (s *ThrottlingException) Message() string { 6255 if s.Message_ != nil { 6256 return *s.Message_ 6257 } 6258 return "" 6259} 6260 6261// OrigErr always returns nil, satisfies awserr.Error interface. 6262func (s *ThrottlingException) OrigErr() error { 6263 return nil 6264} 6265 6266func (s *ThrottlingException) Error() string { 6267 return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) 6268} 6269 6270// Status code returns the HTTP status code for the request's response error. 6271func (s *ThrottlingException) StatusCode() int { 6272 return s.RespMetadata.StatusCode 6273} 6274 6275// RequestID returns the service's response RequestID for request. 6276func (s *ThrottlingException) RequestID() string { 6277 return s.RespMetadata.RequestID 6278} 6279 6280// Describes the registration of a transit gateway to a global network. 6281type TransitGatewayRegistration struct { 6282 _ struct{} `type:"structure"` 6283 6284 // The ID of the global network. 6285 GlobalNetworkId *string `type:"string"` 6286 6287 // The state of the transit gateway registration. 6288 State *TransitGatewayRegistrationStateReason `type:"structure"` 6289 6290 // The Amazon Resource Name (ARN) of the transit gateway. 6291 TransitGatewayArn *string `type:"string"` 6292} 6293 6294// String returns the string representation 6295func (s TransitGatewayRegistration) String() string { 6296 return awsutil.Prettify(s) 6297} 6298 6299// GoString returns the string representation 6300func (s TransitGatewayRegistration) GoString() string { 6301 return s.String() 6302} 6303 6304// SetGlobalNetworkId sets the GlobalNetworkId field's value. 6305func (s *TransitGatewayRegistration) SetGlobalNetworkId(v string) *TransitGatewayRegistration { 6306 s.GlobalNetworkId = &v 6307 return s 6308} 6309 6310// SetState sets the State field's value. 6311func (s *TransitGatewayRegistration) SetState(v *TransitGatewayRegistrationStateReason) *TransitGatewayRegistration { 6312 s.State = v 6313 return s 6314} 6315 6316// SetTransitGatewayArn sets the TransitGatewayArn field's value. 6317func (s *TransitGatewayRegistration) SetTransitGatewayArn(v string) *TransitGatewayRegistration { 6318 s.TransitGatewayArn = &v 6319 return s 6320} 6321 6322// Describes the status of a transit gateway registration. 6323type TransitGatewayRegistrationStateReason struct { 6324 _ struct{} `type:"structure"` 6325 6326 // The code for the state reason. 6327 Code *string `type:"string" enum:"TransitGatewayRegistrationState"` 6328 6329 // The message for the state reason. 6330 Message *string `type:"string"` 6331} 6332 6333// String returns the string representation 6334func (s TransitGatewayRegistrationStateReason) String() string { 6335 return awsutil.Prettify(s) 6336} 6337 6338// GoString returns the string representation 6339func (s TransitGatewayRegistrationStateReason) GoString() string { 6340 return s.String() 6341} 6342 6343// SetCode sets the Code field's value. 6344func (s *TransitGatewayRegistrationStateReason) SetCode(v string) *TransitGatewayRegistrationStateReason { 6345 s.Code = &v 6346 return s 6347} 6348 6349// SetMessage sets the Message field's value. 6350func (s *TransitGatewayRegistrationStateReason) SetMessage(v string) *TransitGatewayRegistrationStateReason { 6351 s.Message = &v 6352 return s 6353} 6354 6355type UntagResourceInput struct { 6356 _ struct{} `type:"structure"` 6357 6358 // The Amazon Resource Name (ARN) of the resource. 6359 // 6360 // ResourceArn is a required field 6361 ResourceArn *string `location:"uri" locationName:"resourceArn" type:"string" required:"true"` 6362 6363 // The tag keys to remove from the specified resource. 6364 // 6365 // TagKeys is a required field 6366 TagKeys []*string `location:"querystring" locationName:"tagKeys" type:"list" required:"true"` 6367} 6368 6369// String returns the string representation 6370func (s UntagResourceInput) String() string { 6371 return awsutil.Prettify(s) 6372} 6373 6374// GoString returns the string representation 6375func (s UntagResourceInput) GoString() string { 6376 return s.String() 6377} 6378 6379// Validate inspects the fields of the type to determine if they are valid. 6380func (s *UntagResourceInput) Validate() error { 6381 invalidParams := request.ErrInvalidParams{Context: "UntagResourceInput"} 6382 if s.ResourceArn == nil { 6383 invalidParams.Add(request.NewErrParamRequired("ResourceArn")) 6384 } 6385 if s.ResourceArn != nil && len(*s.ResourceArn) < 1 { 6386 invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 1)) 6387 } 6388 if s.TagKeys == nil { 6389 invalidParams.Add(request.NewErrParamRequired("TagKeys")) 6390 } 6391 6392 if invalidParams.Len() > 0 { 6393 return invalidParams 6394 } 6395 return nil 6396} 6397 6398// SetResourceArn sets the ResourceArn field's value. 6399func (s *UntagResourceInput) SetResourceArn(v string) *UntagResourceInput { 6400 s.ResourceArn = &v 6401 return s 6402} 6403 6404// SetTagKeys sets the TagKeys field's value. 6405func (s *UntagResourceInput) SetTagKeys(v []*string) *UntagResourceInput { 6406 s.TagKeys = v 6407 return s 6408} 6409 6410type UntagResourceOutput struct { 6411 _ struct{} `type:"structure"` 6412} 6413 6414// String returns the string representation 6415func (s UntagResourceOutput) String() string { 6416 return awsutil.Prettify(s) 6417} 6418 6419// GoString returns the string representation 6420func (s UntagResourceOutput) GoString() string { 6421 return s.String() 6422} 6423 6424type UpdateDeviceInput struct { 6425 _ struct{} `type:"structure"` 6426 6427 // A description of the device. 6428 // 6429 // Length Constraints: Maximum length of 256 characters. 6430 Description *string `type:"string"` 6431 6432 // The ID of the device. 6433 // 6434 // DeviceId is a required field 6435 DeviceId *string `location:"uri" locationName:"deviceId" type:"string" required:"true"` 6436 6437 // The ID of the global network. 6438 // 6439 // GlobalNetworkId is a required field 6440 GlobalNetworkId *string `location:"uri" locationName:"globalNetworkId" type:"string" required:"true"` 6441 6442 // Describes a location. 6443 Location *Location `type:"structure"` 6444 6445 // The model of the device. 6446 // 6447 // Length Constraints: Maximum length of 128 characters. 6448 Model *string `type:"string"` 6449 6450 // The serial number of the device. 6451 // 6452 // Length Constraints: Maximum length of 128 characters. 6453 SerialNumber *string `type:"string"` 6454 6455 // The ID of the site. 6456 SiteId *string `type:"string"` 6457 6458 // The type of the device. 6459 Type *string `type:"string"` 6460 6461 // The vendor of the device. 6462 // 6463 // Length Constraints: Maximum length of 128 characters. 6464 Vendor *string `type:"string"` 6465} 6466 6467// String returns the string representation 6468func (s UpdateDeviceInput) String() string { 6469 return awsutil.Prettify(s) 6470} 6471 6472// GoString returns the string representation 6473func (s UpdateDeviceInput) GoString() string { 6474 return s.String() 6475} 6476 6477// Validate inspects the fields of the type to determine if they are valid. 6478func (s *UpdateDeviceInput) Validate() error { 6479 invalidParams := request.ErrInvalidParams{Context: "UpdateDeviceInput"} 6480 if s.DeviceId == nil { 6481 invalidParams.Add(request.NewErrParamRequired("DeviceId")) 6482 } 6483 if s.DeviceId != nil && len(*s.DeviceId) < 1 { 6484 invalidParams.Add(request.NewErrParamMinLen("DeviceId", 1)) 6485 } 6486 if s.GlobalNetworkId == nil { 6487 invalidParams.Add(request.NewErrParamRequired("GlobalNetworkId")) 6488 } 6489 if s.GlobalNetworkId != nil && len(*s.GlobalNetworkId) < 1 { 6490 invalidParams.Add(request.NewErrParamMinLen("GlobalNetworkId", 1)) 6491 } 6492 6493 if invalidParams.Len() > 0 { 6494 return invalidParams 6495 } 6496 return nil 6497} 6498 6499// SetDescription sets the Description field's value. 6500func (s *UpdateDeviceInput) SetDescription(v string) *UpdateDeviceInput { 6501 s.Description = &v 6502 return s 6503} 6504 6505// SetDeviceId sets the DeviceId field's value. 6506func (s *UpdateDeviceInput) SetDeviceId(v string) *UpdateDeviceInput { 6507 s.DeviceId = &v 6508 return s 6509} 6510 6511// SetGlobalNetworkId sets the GlobalNetworkId field's value. 6512func (s *UpdateDeviceInput) SetGlobalNetworkId(v string) *UpdateDeviceInput { 6513 s.GlobalNetworkId = &v 6514 return s 6515} 6516 6517// SetLocation sets the Location field's value. 6518func (s *UpdateDeviceInput) SetLocation(v *Location) *UpdateDeviceInput { 6519 s.Location = v 6520 return s 6521} 6522 6523// SetModel sets the Model field's value. 6524func (s *UpdateDeviceInput) SetModel(v string) *UpdateDeviceInput { 6525 s.Model = &v 6526 return s 6527} 6528 6529// SetSerialNumber sets the SerialNumber field's value. 6530func (s *UpdateDeviceInput) SetSerialNumber(v string) *UpdateDeviceInput { 6531 s.SerialNumber = &v 6532 return s 6533} 6534 6535// SetSiteId sets the SiteId field's value. 6536func (s *UpdateDeviceInput) SetSiteId(v string) *UpdateDeviceInput { 6537 s.SiteId = &v 6538 return s 6539} 6540 6541// SetType sets the Type field's value. 6542func (s *UpdateDeviceInput) SetType(v string) *UpdateDeviceInput { 6543 s.Type = &v 6544 return s 6545} 6546 6547// SetVendor sets the Vendor field's value. 6548func (s *UpdateDeviceInput) SetVendor(v string) *UpdateDeviceInput { 6549 s.Vendor = &v 6550 return s 6551} 6552 6553type UpdateDeviceOutput struct { 6554 _ struct{} `type:"structure"` 6555 6556 // Information about the device. 6557 Device *Device `type:"structure"` 6558} 6559 6560// String returns the string representation 6561func (s UpdateDeviceOutput) String() string { 6562 return awsutil.Prettify(s) 6563} 6564 6565// GoString returns the string representation 6566func (s UpdateDeviceOutput) GoString() string { 6567 return s.String() 6568} 6569 6570// SetDevice sets the Device field's value. 6571func (s *UpdateDeviceOutput) SetDevice(v *Device) *UpdateDeviceOutput { 6572 s.Device = v 6573 return s 6574} 6575 6576type UpdateGlobalNetworkInput struct { 6577 _ struct{} `type:"structure"` 6578 6579 // A description of the global network. 6580 // 6581 // Length Constraints: Maximum length of 256 characters. 6582 Description *string `type:"string"` 6583 6584 // The ID of your global network. 6585 // 6586 // GlobalNetworkId is a required field 6587 GlobalNetworkId *string `location:"uri" locationName:"globalNetworkId" type:"string" required:"true"` 6588} 6589 6590// String returns the string representation 6591func (s UpdateGlobalNetworkInput) String() string { 6592 return awsutil.Prettify(s) 6593} 6594 6595// GoString returns the string representation 6596func (s UpdateGlobalNetworkInput) GoString() string { 6597 return s.String() 6598} 6599 6600// Validate inspects the fields of the type to determine if they are valid. 6601func (s *UpdateGlobalNetworkInput) Validate() error { 6602 invalidParams := request.ErrInvalidParams{Context: "UpdateGlobalNetworkInput"} 6603 if s.GlobalNetworkId == nil { 6604 invalidParams.Add(request.NewErrParamRequired("GlobalNetworkId")) 6605 } 6606 if s.GlobalNetworkId != nil && len(*s.GlobalNetworkId) < 1 { 6607 invalidParams.Add(request.NewErrParamMinLen("GlobalNetworkId", 1)) 6608 } 6609 6610 if invalidParams.Len() > 0 { 6611 return invalidParams 6612 } 6613 return nil 6614} 6615 6616// SetDescription sets the Description field's value. 6617func (s *UpdateGlobalNetworkInput) SetDescription(v string) *UpdateGlobalNetworkInput { 6618 s.Description = &v 6619 return s 6620} 6621 6622// SetGlobalNetworkId sets the GlobalNetworkId field's value. 6623func (s *UpdateGlobalNetworkInput) SetGlobalNetworkId(v string) *UpdateGlobalNetworkInput { 6624 s.GlobalNetworkId = &v 6625 return s 6626} 6627 6628type UpdateGlobalNetworkOutput struct { 6629 _ struct{} `type:"structure"` 6630 6631 // Information about the global network object. 6632 GlobalNetwork *GlobalNetwork `type:"structure"` 6633} 6634 6635// String returns the string representation 6636func (s UpdateGlobalNetworkOutput) String() string { 6637 return awsutil.Prettify(s) 6638} 6639 6640// GoString returns the string representation 6641func (s UpdateGlobalNetworkOutput) GoString() string { 6642 return s.String() 6643} 6644 6645// SetGlobalNetwork sets the GlobalNetwork field's value. 6646func (s *UpdateGlobalNetworkOutput) SetGlobalNetwork(v *GlobalNetwork) *UpdateGlobalNetworkOutput { 6647 s.GlobalNetwork = v 6648 return s 6649} 6650 6651type UpdateLinkInput struct { 6652 _ struct{} `type:"structure"` 6653 6654 // The upload and download speed in Mbps. 6655 Bandwidth *Bandwidth `type:"structure"` 6656 6657 // A description of the link. 6658 // 6659 // Length Constraints: Maximum length of 256 characters. 6660 Description *string `type:"string"` 6661 6662 // The ID of the global network. 6663 // 6664 // GlobalNetworkId is a required field 6665 GlobalNetworkId *string `location:"uri" locationName:"globalNetworkId" type:"string" required:"true"` 6666 6667 // The ID of the link. 6668 // 6669 // LinkId is a required field 6670 LinkId *string `location:"uri" locationName:"linkId" type:"string" required:"true"` 6671 6672 // The provider of the link. 6673 // 6674 // Length Constraints: Maximum length of 128 characters. 6675 Provider *string `type:"string"` 6676 6677 // The type of the link. 6678 // 6679 // Length Constraints: Maximum length of 128 characters. 6680 Type *string `type:"string"` 6681} 6682 6683// String returns the string representation 6684func (s UpdateLinkInput) String() string { 6685 return awsutil.Prettify(s) 6686} 6687 6688// GoString returns the string representation 6689func (s UpdateLinkInput) GoString() string { 6690 return s.String() 6691} 6692 6693// Validate inspects the fields of the type to determine if they are valid. 6694func (s *UpdateLinkInput) Validate() error { 6695 invalidParams := request.ErrInvalidParams{Context: "UpdateLinkInput"} 6696 if s.GlobalNetworkId == nil { 6697 invalidParams.Add(request.NewErrParamRequired("GlobalNetworkId")) 6698 } 6699 if s.GlobalNetworkId != nil && len(*s.GlobalNetworkId) < 1 { 6700 invalidParams.Add(request.NewErrParamMinLen("GlobalNetworkId", 1)) 6701 } 6702 if s.LinkId == nil { 6703 invalidParams.Add(request.NewErrParamRequired("LinkId")) 6704 } 6705 if s.LinkId != nil && len(*s.LinkId) < 1 { 6706 invalidParams.Add(request.NewErrParamMinLen("LinkId", 1)) 6707 } 6708 6709 if invalidParams.Len() > 0 { 6710 return invalidParams 6711 } 6712 return nil 6713} 6714 6715// SetBandwidth sets the Bandwidth field's value. 6716func (s *UpdateLinkInput) SetBandwidth(v *Bandwidth) *UpdateLinkInput { 6717 s.Bandwidth = v 6718 return s 6719} 6720 6721// SetDescription sets the Description field's value. 6722func (s *UpdateLinkInput) SetDescription(v string) *UpdateLinkInput { 6723 s.Description = &v 6724 return s 6725} 6726 6727// SetGlobalNetworkId sets the GlobalNetworkId field's value. 6728func (s *UpdateLinkInput) SetGlobalNetworkId(v string) *UpdateLinkInput { 6729 s.GlobalNetworkId = &v 6730 return s 6731} 6732 6733// SetLinkId sets the LinkId field's value. 6734func (s *UpdateLinkInput) SetLinkId(v string) *UpdateLinkInput { 6735 s.LinkId = &v 6736 return s 6737} 6738 6739// SetProvider sets the Provider field's value. 6740func (s *UpdateLinkInput) SetProvider(v string) *UpdateLinkInput { 6741 s.Provider = &v 6742 return s 6743} 6744 6745// SetType sets the Type field's value. 6746func (s *UpdateLinkInput) SetType(v string) *UpdateLinkInput { 6747 s.Type = &v 6748 return s 6749} 6750 6751type UpdateLinkOutput struct { 6752 _ struct{} `type:"structure"` 6753 6754 // Information about the link. 6755 Link *Link `type:"structure"` 6756} 6757 6758// String returns the string representation 6759func (s UpdateLinkOutput) String() string { 6760 return awsutil.Prettify(s) 6761} 6762 6763// GoString returns the string representation 6764func (s UpdateLinkOutput) GoString() string { 6765 return s.String() 6766} 6767 6768// SetLink sets the Link field's value. 6769func (s *UpdateLinkOutput) SetLink(v *Link) *UpdateLinkOutput { 6770 s.Link = v 6771 return s 6772} 6773 6774type UpdateSiteInput struct { 6775 _ struct{} `type:"structure"` 6776 6777 // A description of your site. 6778 // 6779 // Length Constraints: Maximum length of 256 characters. 6780 Description *string `type:"string"` 6781 6782 // The ID of the global network. 6783 // 6784 // GlobalNetworkId is a required field 6785 GlobalNetworkId *string `location:"uri" locationName:"globalNetworkId" type:"string" required:"true"` 6786 6787 // The site location: 6788 // 6789 // * Address: The physical address of the site. 6790 // 6791 // * Latitude: The latitude of the site. 6792 // 6793 // * Longitude: The longitude of the site. 6794 Location *Location `type:"structure"` 6795 6796 // The ID of your site. 6797 // 6798 // SiteId is a required field 6799 SiteId *string `location:"uri" locationName:"siteId" type:"string" required:"true"` 6800} 6801 6802// String returns the string representation 6803func (s UpdateSiteInput) String() string { 6804 return awsutil.Prettify(s) 6805} 6806 6807// GoString returns the string representation 6808func (s UpdateSiteInput) GoString() string { 6809 return s.String() 6810} 6811 6812// Validate inspects the fields of the type to determine if they are valid. 6813func (s *UpdateSiteInput) Validate() error { 6814 invalidParams := request.ErrInvalidParams{Context: "UpdateSiteInput"} 6815 if s.GlobalNetworkId == nil { 6816 invalidParams.Add(request.NewErrParamRequired("GlobalNetworkId")) 6817 } 6818 if s.GlobalNetworkId != nil && len(*s.GlobalNetworkId) < 1 { 6819 invalidParams.Add(request.NewErrParamMinLen("GlobalNetworkId", 1)) 6820 } 6821 if s.SiteId == nil { 6822 invalidParams.Add(request.NewErrParamRequired("SiteId")) 6823 } 6824 if s.SiteId != nil && len(*s.SiteId) < 1 { 6825 invalidParams.Add(request.NewErrParamMinLen("SiteId", 1)) 6826 } 6827 6828 if invalidParams.Len() > 0 { 6829 return invalidParams 6830 } 6831 return nil 6832} 6833 6834// SetDescription sets the Description field's value. 6835func (s *UpdateSiteInput) SetDescription(v string) *UpdateSiteInput { 6836 s.Description = &v 6837 return s 6838} 6839 6840// SetGlobalNetworkId sets the GlobalNetworkId field's value. 6841func (s *UpdateSiteInput) SetGlobalNetworkId(v string) *UpdateSiteInput { 6842 s.GlobalNetworkId = &v 6843 return s 6844} 6845 6846// SetLocation sets the Location field's value. 6847func (s *UpdateSiteInput) SetLocation(v *Location) *UpdateSiteInput { 6848 s.Location = v 6849 return s 6850} 6851 6852// SetSiteId sets the SiteId field's value. 6853func (s *UpdateSiteInput) SetSiteId(v string) *UpdateSiteInput { 6854 s.SiteId = &v 6855 return s 6856} 6857 6858type UpdateSiteOutput struct { 6859 _ struct{} `type:"structure"` 6860 6861 // Information about the site. 6862 Site *Site `type:"structure"` 6863} 6864 6865// String returns the string representation 6866func (s UpdateSiteOutput) String() string { 6867 return awsutil.Prettify(s) 6868} 6869 6870// GoString returns the string representation 6871func (s UpdateSiteOutput) GoString() string { 6872 return s.String() 6873} 6874 6875// SetSite sets the Site field's value. 6876func (s *UpdateSiteOutput) SetSite(v *Site) *UpdateSiteOutput { 6877 s.Site = v 6878 return s 6879} 6880 6881// The input fails to satisfy the constraints. 6882type ValidationException struct { 6883 _ struct{} `type:"structure"` 6884 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 6885 6886 // The fields that caused the error, if applicable. 6887 Fields []*ValidationExceptionField `type:"list"` 6888 6889 Message_ *string `locationName:"Message" type:"string"` 6890 6891 // The reason for the error. 6892 Reason *string `type:"string" enum:"ValidationExceptionReason"` 6893} 6894 6895// String returns the string representation 6896func (s ValidationException) String() string { 6897 return awsutil.Prettify(s) 6898} 6899 6900// GoString returns the string representation 6901func (s ValidationException) GoString() string { 6902 return s.String() 6903} 6904 6905func newErrorValidationException(v protocol.ResponseMetadata) error { 6906 return &ValidationException{ 6907 RespMetadata: v, 6908 } 6909} 6910 6911// Code returns the exception type name. 6912func (s *ValidationException) Code() string { 6913 return "ValidationException" 6914} 6915 6916// Message returns the exception's message. 6917func (s *ValidationException) Message() string { 6918 if s.Message_ != nil { 6919 return *s.Message_ 6920 } 6921 return "" 6922} 6923 6924// OrigErr always returns nil, satisfies awserr.Error interface. 6925func (s *ValidationException) OrigErr() error { 6926 return nil 6927} 6928 6929func (s *ValidationException) Error() string { 6930 return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) 6931} 6932 6933// Status code returns the HTTP status code for the request's response error. 6934func (s *ValidationException) StatusCode() int { 6935 return s.RespMetadata.StatusCode 6936} 6937 6938// RequestID returns the service's response RequestID for request. 6939func (s *ValidationException) RequestID() string { 6940 return s.RespMetadata.RequestID 6941} 6942 6943// Describes a validation exception for a field. 6944type ValidationExceptionField struct { 6945 _ struct{} `type:"structure"` 6946 6947 // The message for the field. 6948 // 6949 // Message is a required field 6950 Message *string `type:"string" required:"true"` 6951 6952 // The name of the field. 6953 // 6954 // Name is a required field 6955 Name *string `type:"string" required:"true"` 6956} 6957 6958// String returns the string representation 6959func (s ValidationExceptionField) String() string { 6960 return awsutil.Prettify(s) 6961} 6962 6963// GoString returns the string representation 6964func (s ValidationExceptionField) GoString() string { 6965 return s.String() 6966} 6967 6968// SetMessage sets the Message field's value. 6969func (s *ValidationExceptionField) SetMessage(v string) *ValidationExceptionField { 6970 s.Message = &v 6971 return s 6972} 6973 6974// SetName sets the Name field's value. 6975func (s *ValidationExceptionField) SetName(v string) *ValidationExceptionField { 6976 s.Name = &v 6977 return s 6978} 6979 6980const ( 6981 // CustomerGatewayAssociationStatePending is a CustomerGatewayAssociationState enum value 6982 CustomerGatewayAssociationStatePending = "PENDING" 6983 6984 // CustomerGatewayAssociationStateAvailable is a CustomerGatewayAssociationState enum value 6985 CustomerGatewayAssociationStateAvailable = "AVAILABLE" 6986 6987 // CustomerGatewayAssociationStateDeleting is a CustomerGatewayAssociationState enum value 6988 CustomerGatewayAssociationStateDeleting = "DELETING" 6989 6990 // CustomerGatewayAssociationStateDeleted is a CustomerGatewayAssociationState enum value 6991 CustomerGatewayAssociationStateDeleted = "DELETED" 6992) 6993 6994const ( 6995 // DeviceStatePending is a DeviceState enum value 6996 DeviceStatePending = "PENDING" 6997 6998 // DeviceStateAvailable is a DeviceState enum value 6999 DeviceStateAvailable = "AVAILABLE" 7000 7001 // DeviceStateDeleting is a DeviceState enum value 7002 DeviceStateDeleting = "DELETING" 7003 7004 // DeviceStateUpdating is a DeviceState enum value 7005 DeviceStateUpdating = "UPDATING" 7006) 7007 7008const ( 7009 // GlobalNetworkStatePending is a GlobalNetworkState enum value 7010 GlobalNetworkStatePending = "PENDING" 7011 7012 // GlobalNetworkStateAvailable is a GlobalNetworkState enum value 7013 GlobalNetworkStateAvailable = "AVAILABLE" 7014 7015 // GlobalNetworkStateDeleting is a GlobalNetworkState enum value 7016 GlobalNetworkStateDeleting = "DELETING" 7017 7018 // GlobalNetworkStateUpdating is a GlobalNetworkState enum value 7019 GlobalNetworkStateUpdating = "UPDATING" 7020) 7021 7022const ( 7023 // LinkAssociationStatePending is a LinkAssociationState enum value 7024 LinkAssociationStatePending = "PENDING" 7025 7026 // LinkAssociationStateAvailable is a LinkAssociationState enum value 7027 LinkAssociationStateAvailable = "AVAILABLE" 7028 7029 // LinkAssociationStateDeleting is a LinkAssociationState enum value 7030 LinkAssociationStateDeleting = "DELETING" 7031 7032 // LinkAssociationStateDeleted is a LinkAssociationState enum value 7033 LinkAssociationStateDeleted = "DELETED" 7034) 7035 7036const ( 7037 // LinkStatePending is a LinkState enum value 7038 LinkStatePending = "PENDING" 7039 7040 // LinkStateAvailable is a LinkState enum value 7041 LinkStateAvailable = "AVAILABLE" 7042 7043 // LinkStateDeleting is a LinkState enum value 7044 LinkStateDeleting = "DELETING" 7045 7046 // LinkStateUpdating is a LinkState enum value 7047 LinkStateUpdating = "UPDATING" 7048) 7049 7050const ( 7051 // SiteStatePending is a SiteState enum value 7052 SiteStatePending = "PENDING" 7053 7054 // SiteStateAvailable is a SiteState enum value 7055 SiteStateAvailable = "AVAILABLE" 7056 7057 // SiteStateDeleting is a SiteState enum value 7058 SiteStateDeleting = "DELETING" 7059 7060 // SiteStateUpdating is a SiteState enum value 7061 SiteStateUpdating = "UPDATING" 7062) 7063 7064const ( 7065 // TransitGatewayRegistrationStatePending is a TransitGatewayRegistrationState enum value 7066 TransitGatewayRegistrationStatePending = "PENDING" 7067 7068 // TransitGatewayRegistrationStateAvailable is a TransitGatewayRegistrationState enum value 7069 TransitGatewayRegistrationStateAvailable = "AVAILABLE" 7070 7071 // TransitGatewayRegistrationStateDeleting is a TransitGatewayRegistrationState enum value 7072 TransitGatewayRegistrationStateDeleting = "DELETING" 7073 7074 // TransitGatewayRegistrationStateDeleted is a TransitGatewayRegistrationState enum value 7075 TransitGatewayRegistrationStateDeleted = "DELETED" 7076 7077 // TransitGatewayRegistrationStateFailed is a TransitGatewayRegistrationState enum value 7078 TransitGatewayRegistrationStateFailed = "FAILED" 7079) 7080 7081const ( 7082 // ValidationExceptionReasonUnknownOperation is a ValidationExceptionReason enum value 7083 ValidationExceptionReasonUnknownOperation = "UnknownOperation" 7084 7085 // ValidationExceptionReasonCannotParse is a ValidationExceptionReason enum value 7086 ValidationExceptionReasonCannotParse = "CannotParse" 7087 7088 // ValidationExceptionReasonFieldValidationFailed is a ValidationExceptionReason enum value 7089 ValidationExceptionReasonFieldValidationFailed = "FieldValidationFailed" 7090 7091 // ValidationExceptionReasonOther is a ValidationExceptionReason enum value 7092 ValidationExceptionReasonOther = "Other" 7093) 7094