src

Go monorepo.
git clone git://code.dwrz.net/src
Log | Files | Refs

api_op_GetDNSSEC.go (3932B)


      1 // Code generated by smithy-go-codegen DO NOT EDIT.
      2 
      3 package route53
      4 
      5 import (
      6 	"context"
      7 	"fmt"
      8 	awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
      9 	"github.com/aws/aws-sdk-go-v2/service/route53/types"
     10 	"github.com/aws/smithy-go/middleware"
     11 	smithyhttp "github.com/aws/smithy-go/transport/http"
     12 )
     13 
     14 // Returns information about DNSSEC for a specific hosted zone, including the
     15 // key-signing keys (KSKs) in the hosted zone.
     16 func (c *Client) GetDNSSEC(ctx context.Context, params *GetDNSSECInput, optFns ...func(*Options)) (*GetDNSSECOutput, error) {
     17 	if params == nil {
     18 		params = &GetDNSSECInput{}
     19 	}
     20 
     21 	result, metadata, err := c.invokeOperation(ctx, "GetDNSSEC", params, optFns, c.addOperationGetDNSSECMiddlewares)
     22 	if err != nil {
     23 		return nil, err
     24 	}
     25 
     26 	out := result.(*GetDNSSECOutput)
     27 	out.ResultMetadata = metadata
     28 	return out, nil
     29 }
     30 
     31 type GetDNSSECInput struct {
     32 
     33 	// A unique string used to identify a hosted zone.
     34 	//
     35 	// This member is required.
     36 	HostedZoneId *string
     37 
     38 	noSmithyDocumentSerde
     39 }
     40 
     41 type GetDNSSECOutput struct {
     42 
     43 	// The key-signing keys (KSKs) in your account.
     44 	//
     45 	// This member is required.
     46 	KeySigningKeys []types.KeySigningKey
     47 
     48 	// A string representing the status of DNSSEC.
     49 	//
     50 	// This member is required.
     51 	Status *types.DNSSECStatus
     52 
     53 	// Metadata pertaining to the operation's result.
     54 	ResultMetadata middleware.Metadata
     55 
     56 	noSmithyDocumentSerde
     57 }
     58 
     59 func (c *Client) addOperationGetDNSSECMiddlewares(stack *middleware.Stack, options Options) (err error) {
     60 	if err := stack.Serialize.Add(&setOperationInputMiddleware{}, middleware.After); err != nil {
     61 		return err
     62 	}
     63 	err = stack.Serialize.Add(&awsRestxml_serializeOpGetDNSSEC{}, middleware.After)
     64 	if err != nil {
     65 		return err
     66 	}
     67 	err = stack.Deserialize.Add(&awsRestxml_deserializeOpGetDNSSEC{}, middleware.After)
     68 	if err != nil {
     69 		return err
     70 	}
     71 	if err := addProtocolFinalizerMiddlewares(stack, options, "GetDNSSEC"); err != nil {
     72 		return fmt.Errorf("add protocol finalizers: %v", err)
     73 	}
     74 
     75 	if err = addlegacyEndpointContextSetter(stack, options); err != nil {
     76 		return err
     77 	}
     78 	if err = addSetLoggerMiddleware(stack, options); err != nil {
     79 		return err
     80 	}
     81 	if err = addClientRequestID(stack); err != nil {
     82 		return err
     83 	}
     84 	if err = addComputeContentLength(stack); err != nil {
     85 		return err
     86 	}
     87 	if err = addResolveEndpointMiddleware(stack, options); err != nil {
     88 		return err
     89 	}
     90 	if err = addComputePayloadSHA256(stack); err != nil {
     91 		return err
     92 	}
     93 	if err = addRetry(stack, options); err != nil {
     94 		return err
     95 	}
     96 	if err = addRawResponseToMetadata(stack); err != nil {
     97 		return err
     98 	}
     99 	if err = addRecordResponseTiming(stack); err != nil {
    100 		return err
    101 	}
    102 	if err = addClientUserAgent(stack, options); err != nil {
    103 		return err
    104 	}
    105 	if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
    106 		return err
    107 	}
    108 	if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
    109 		return err
    110 	}
    111 	if err = addSetLegacyContextSigningOptionsMiddleware(stack); err != nil {
    112 		return err
    113 	}
    114 	if err = addOpGetDNSSECValidationMiddleware(stack); err != nil {
    115 		return err
    116 	}
    117 	if err = stack.Initialize.Add(newServiceMetadataMiddleware_opGetDNSSEC(options.Region), middleware.Before); err != nil {
    118 		return err
    119 	}
    120 	if err = addRecursionDetection(stack); err != nil {
    121 		return err
    122 	}
    123 	if err = addRequestIDRetrieverMiddleware(stack); err != nil {
    124 		return err
    125 	}
    126 	if err = addResponseErrorMiddleware(stack); err != nil {
    127 		return err
    128 	}
    129 	if err = addSanitizeURLMiddleware(stack); err != nil {
    130 		return err
    131 	}
    132 	if err = addRequestResponseLogging(stack, options); err != nil {
    133 		return err
    134 	}
    135 	if err = addDisableHTTPSMiddleware(stack, options); err != nil {
    136 		return err
    137 	}
    138 	return nil
    139 }
    140 
    141 func newServiceMetadataMiddleware_opGetDNSSEC(region string) *awsmiddleware.RegisterServiceMetadata {
    142 	return &awsmiddleware.RegisterServiceMetadata{
    143 		Region:        region,
    144 		ServiceID:     ServiceID,
    145 		OperationName: "GetDNSSEC",
    146 	}
    147 }