github.com/aavshr/aws-sdk-go@v1.41.3/service/servicediscovery/servicediscoveryiface/interface.go (about)

     1  // Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
     2  
     3  // Package servicediscoveryiface provides an interface to enable mocking the AWS Cloud Map service client
     4  // for testing your code.
     5  //
     6  // It is important to note that this interface will have breaking changes
     7  // when the service model is updated and adds new API operations, paginators,
     8  // and waiters.
     9  package servicediscoveryiface
    10  
    11  import (
    12  	"github.com/aavshr/aws-sdk-go/aws"
    13  	"github.com/aavshr/aws-sdk-go/aws/request"
    14  	"github.com/aavshr/aws-sdk-go/service/servicediscovery"
    15  )
    16  
    17  // ServiceDiscoveryAPI provides an interface to enable mocking the
    18  // servicediscovery.ServiceDiscovery service client's API operation,
    19  // paginators, and waiters. This make unit testing your code that calls out
    20  // to the SDK's service client's calls easier.
    21  //
    22  // The best way to use this interface is so the SDK's service client's calls
    23  // can be stubbed out for unit testing your code with the SDK without needing
    24  // to inject custom request handlers into the SDK's request pipeline.
    25  //
    26  //    // myFunc uses an SDK service client to make a request to
    27  //    // AWS Cloud Map.
    28  //    func myFunc(svc servicediscoveryiface.ServiceDiscoveryAPI) bool {
    29  //        // Make svc.CreateHttpNamespace request
    30  //    }
    31  //
    32  //    func main() {
    33  //        sess := session.New()
    34  //        svc := servicediscovery.New(sess)
    35  //
    36  //        myFunc(svc)
    37  //    }
    38  //
    39  // In your _test.go file:
    40  //
    41  //    // Define a mock struct to be used in your unit tests of myFunc.
    42  //    type mockServiceDiscoveryClient struct {
    43  //        servicediscoveryiface.ServiceDiscoveryAPI
    44  //    }
    45  //    func (m *mockServiceDiscoveryClient) CreateHttpNamespace(input *servicediscovery.CreateHttpNamespaceInput) (*servicediscovery.CreateHttpNamespaceOutput, error) {
    46  //        // mock response/functionality
    47  //    }
    48  //
    49  //    func TestMyFunc(t *testing.T) {
    50  //        // Setup Test
    51  //        mockSvc := &mockServiceDiscoveryClient{}
    52  //
    53  //        myfunc(mockSvc)
    54  //
    55  //        // Verify myFunc's functionality
    56  //    }
    57  //
    58  // It is important to note that this interface will have breaking changes
    59  // when the service model is updated and adds new API operations, paginators,
    60  // and waiters. Its suggested to use the pattern above for testing, or using
    61  // tooling to generate mocks to satisfy the interfaces.
    62  type ServiceDiscoveryAPI interface {
    63  	CreateHttpNamespace(*servicediscovery.CreateHttpNamespaceInput) (*servicediscovery.CreateHttpNamespaceOutput, error)
    64  	CreateHttpNamespaceWithContext(aws.Context, *servicediscovery.CreateHttpNamespaceInput, ...request.Option) (*servicediscovery.CreateHttpNamespaceOutput, error)
    65  	CreateHttpNamespaceRequest(*servicediscovery.CreateHttpNamespaceInput) (*request.Request, *servicediscovery.CreateHttpNamespaceOutput)
    66  
    67  	CreatePrivateDnsNamespace(*servicediscovery.CreatePrivateDnsNamespaceInput) (*servicediscovery.CreatePrivateDnsNamespaceOutput, error)
    68  	CreatePrivateDnsNamespaceWithContext(aws.Context, *servicediscovery.CreatePrivateDnsNamespaceInput, ...request.Option) (*servicediscovery.CreatePrivateDnsNamespaceOutput, error)
    69  	CreatePrivateDnsNamespaceRequest(*servicediscovery.CreatePrivateDnsNamespaceInput) (*request.Request, *servicediscovery.CreatePrivateDnsNamespaceOutput)
    70  
    71  	CreatePublicDnsNamespace(*servicediscovery.CreatePublicDnsNamespaceInput) (*servicediscovery.CreatePublicDnsNamespaceOutput, error)
    72  	CreatePublicDnsNamespaceWithContext(aws.Context, *servicediscovery.CreatePublicDnsNamespaceInput, ...request.Option) (*servicediscovery.CreatePublicDnsNamespaceOutput, error)
    73  	CreatePublicDnsNamespaceRequest(*servicediscovery.CreatePublicDnsNamespaceInput) (*request.Request, *servicediscovery.CreatePublicDnsNamespaceOutput)
    74  
    75  	CreateService(*servicediscovery.CreateServiceInput) (*servicediscovery.CreateServiceOutput, error)
    76  	CreateServiceWithContext(aws.Context, *servicediscovery.CreateServiceInput, ...request.Option) (*servicediscovery.CreateServiceOutput, error)
    77  	CreateServiceRequest(*servicediscovery.CreateServiceInput) (*request.Request, *servicediscovery.CreateServiceOutput)
    78  
    79  	DeleteNamespace(*servicediscovery.DeleteNamespaceInput) (*servicediscovery.DeleteNamespaceOutput, error)
    80  	DeleteNamespaceWithContext(aws.Context, *servicediscovery.DeleteNamespaceInput, ...request.Option) (*servicediscovery.DeleteNamespaceOutput, error)
    81  	DeleteNamespaceRequest(*servicediscovery.DeleteNamespaceInput) (*request.Request, *servicediscovery.DeleteNamespaceOutput)
    82  
    83  	DeleteService(*servicediscovery.DeleteServiceInput) (*servicediscovery.DeleteServiceOutput, error)
    84  	DeleteServiceWithContext(aws.Context, *servicediscovery.DeleteServiceInput, ...request.Option) (*servicediscovery.DeleteServiceOutput, error)
    85  	DeleteServiceRequest(*servicediscovery.DeleteServiceInput) (*request.Request, *servicediscovery.DeleteServiceOutput)
    86  
    87  	DeregisterInstance(*servicediscovery.DeregisterInstanceInput) (*servicediscovery.DeregisterInstanceOutput, error)
    88  	DeregisterInstanceWithContext(aws.Context, *servicediscovery.DeregisterInstanceInput, ...request.Option) (*servicediscovery.DeregisterInstanceOutput, error)
    89  	DeregisterInstanceRequest(*servicediscovery.DeregisterInstanceInput) (*request.Request, *servicediscovery.DeregisterInstanceOutput)
    90  
    91  	DiscoverInstances(*servicediscovery.DiscoverInstancesInput) (*servicediscovery.DiscoverInstancesOutput, error)
    92  	DiscoverInstancesWithContext(aws.Context, *servicediscovery.DiscoverInstancesInput, ...request.Option) (*servicediscovery.DiscoverInstancesOutput, error)
    93  	DiscoverInstancesRequest(*servicediscovery.DiscoverInstancesInput) (*request.Request, *servicediscovery.DiscoverInstancesOutput)
    94  
    95  	GetInstance(*servicediscovery.GetInstanceInput) (*servicediscovery.GetInstanceOutput, error)
    96  	GetInstanceWithContext(aws.Context, *servicediscovery.GetInstanceInput, ...request.Option) (*servicediscovery.GetInstanceOutput, error)
    97  	GetInstanceRequest(*servicediscovery.GetInstanceInput) (*request.Request, *servicediscovery.GetInstanceOutput)
    98  
    99  	GetInstancesHealthStatus(*servicediscovery.GetInstancesHealthStatusInput) (*servicediscovery.GetInstancesHealthStatusOutput, error)
   100  	GetInstancesHealthStatusWithContext(aws.Context, *servicediscovery.GetInstancesHealthStatusInput, ...request.Option) (*servicediscovery.GetInstancesHealthStatusOutput, error)
   101  	GetInstancesHealthStatusRequest(*servicediscovery.GetInstancesHealthStatusInput) (*request.Request, *servicediscovery.GetInstancesHealthStatusOutput)
   102  
   103  	GetInstancesHealthStatusPages(*servicediscovery.GetInstancesHealthStatusInput, func(*servicediscovery.GetInstancesHealthStatusOutput, bool) bool) error
   104  	GetInstancesHealthStatusPagesWithContext(aws.Context, *servicediscovery.GetInstancesHealthStatusInput, func(*servicediscovery.GetInstancesHealthStatusOutput, bool) bool, ...request.Option) error
   105  
   106  	GetNamespace(*servicediscovery.GetNamespaceInput) (*servicediscovery.GetNamespaceOutput, error)
   107  	GetNamespaceWithContext(aws.Context, *servicediscovery.GetNamespaceInput, ...request.Option) (*servicediscovery.GetNamespaceOutput, error)
   108  	GetNamespaceRequest(*servicediscovery.GetNamespaceInput) (*request.Request, *servicediscovery.GetNamespaceOutput)
   109  
   110  	GetOperation(*servicediscovery.GetOperationInput) (*servicediscovery.GetOperationOutput, error)
   111  	GetOperationWithContext(aws.Context, *servicediscovery.GetOperationInput, ...request.Option) (*servicediscovery.GetOperationOutput, error)
   112  	GetOperationRequest(*servicediscovery.GetOperationInput) (*request.Request, *servicediscovery.GetOperationOutput)
   113  
   114  	GetService(*servicediscovery.GetServiceInput) (*servicediscovery.GetServiceOutput, error)
   115  	GetServiceWithContext(aws.Context, *servicediscovery.GetServiceInput, ...request.Option) (*servicediscovery.GetServiceOutput, error)
   116  	GetServiceRequest(*servicediscovery.GetServiceInput) (*request.Request, *servicediscovery.GetServiceOutput)
   117  
   118  	ListInstances(*servicediscovery.ListInstancesInput) (*servicediscovery.ListInstancesOutput, error)
   119  	ListInstancesWithContext(aws.Context, *servicediscovery.ListInstancesInput, ...request.Option) (*servicediscovery.ListInstancesOutput, error)
   120  	ListInstancesRequest(*servicediscovery.ListInstancesInput) (*request.Request, *servicediscovery.ListInstancesOutput)
   121  
   122  	ListInstancesPages(*servicediscovery.ListInstancesInput, func(*servicediscovery.ListInstancesOutput, bool) bool) error
   123  	ListInstancesPagesWithContext(aws.Context, *servicediscovery.ListInstancesInput, func(*servicediscovery.ListInstancesOutput, bool) bool, ...request.Option) error
   124  
   125  	ListNamespaces(*servicediscovery.ListNamespacesInput) (*servicediscovery.ListNamespacesOutput, error)
   126  	ListNamespacesWithContext(aws.Context, *servicediscovery.ListNamespacesInput, ...request.Option) (*servicediscovery.ListNamespacesOutput, error)
   127  	ListNamespacesRequest(*servicediscovery.ListNamespacesInput) (*request.Request, *servicediscovery.ListNamespacesOutput)
   128  
   129  	ListNamespacesPages(*servicediscovery.ListNamespacesInput, func(*servicediscovery.ListNamespacesOutput, bool) bool) error
   130  	ListNamespacesPagesWithContext(aws.Context, *servicediscovery.ListNamespacesInput, func(*servicediscovery.ListNamespacesOutput, bool) bool, ...request.Option) error
   131  
   132  	ListOperations(*servicediscovery.ListOperationsInput) (*servicediscovery.ListOperationsOutput, error)
   133  	ListOperationsWithContext(aws.Context, *servicediscovery.ListOperationsInput, ...request.Option) (*servicediscovery.ListOperationsOutput, error)
   134  	ListOperationsRequest(*servicediscovery.ListOperationsInput) (*request.Request, *servicediscovery.ListOperationsOutput)
   135  
   136  	ListOperationsPages(*servicediscovery.ListOperationsInput, func(*servicediscovery.ListOperationsOutput, bool) bool) error
   137  	ListOperationsPagesWithContext(aws.Context, *servicediscovery.ListOperationsInput, func(*servicediscovery.ListOperationsOutput, bool) bool, ...request.Option) error
   138  
   139  	ListServices(*servicediscovery.ListServicesInput) (*servicediscovery.ListServicesOutput, error)
   140  	ListServicesWithContext(aws.Context, *servicediscovery.ListServicesInput, ...request.Option) (*servicediscovery.ListServicesOutput, error)
   141  	ListServicesRequest(*servicediscovery.ListServicesInput) (*request.Request, *servicediscovery.ListServicesOutput)
   142  
   143  	ListServicesPages(*servicediscovery.ListServicesInput, func(*servicediscovery.ListServicesOutput, bool) bool) error
   144  	ListServicesPagesWithContext(aws.Context, *servicediscovery.ListServicesInput, func(*servicediscovery.ListServicesOutput, bool) bool, ...request.Option) error
   145  
   146  	ListTagsForResource(*servicediscovery.ListTagsForResourceInput) (*servicediscovery.ListTagsForResourceOutput, error)
   147  	ListTagsForResourceWithContext(aws.Context, *servicediscovery.ListTagsForResourceInput, ...request.Option) (*servicediscovery.ListTagsForResourceOutput, error)
   148  	ListTagsForResourceRequest(*servicediscovery.ListTagsForResourceInput) (*request.Request, *servicediscovery.ListTagsForResourceOutput)
   149  
   150  	RegisterInstance(*servicediscovery.RegisterInstanceInput) (*servicediscovery.RegisterInstanceOutput, error)
   151  	RegisterInstanceWithContext(aws.Context, *servicediscovery.RegisterInstanceInput, ...request.Option) (*servicediscovery.RegisterInstanceOutput, error)
   152  	RegisterInstanceRequest(*servicediscovery.RegisterInstanceInput) (*request.Request, *servicediscovery.RegisterInstanceOutput)
   153  
   154  	TagResource(*servicediscovery.TagResourceInput) (*servicediscovery.TagResourceOutput, error)
   155  	TagResourceWithContext(aws.Context, *servicediscovery.TagResourceInput, ...request.Option) (*servicediscovery.TagResourceOutput, error)
   156  	TagResourceRequest(*servicediscovery.TagResourceInput) (*request.Request, *servicediscovery.TagResourceOutput)
   157  
   158  	UntagResource(*servicediscovery.UntagResourceInput) (*servicediscovery.UntagResourceOutput, error)
   159  	UntagResourceWithContext(aws.Context, *servicediscovery.UntagResourceInput, ...request.Option) (*servicediscovery.UntagResourceOutput, error)
   160  	UntagResourceRequest(*servicediscovery.UntagResourceInput) (*request.Request, *servicediscovery.UntagResourceOutput)
   161  
   162  	UpdateHttpNamespace(*servicediscovery.UpdateHttpNamespaceInput) (*servicediscovery.UpdateHttpNamespaceOutput, error)
   163  	UpdateHttpNamespaceWithContext(aws.Context, *servicediscovery.UpdateHttpNamespaceInput, ...request.Option) (*servicediscovery.UpdateHttpNamespaceOutput, error)
   164  	UpdateHttpNamespaceRequest(*servicediscovery.UpdateHttpNamespaceInput) (*request.Request, *servicediscovery.UpdateHttpNamespaceOutput)
   165  
   166  	UpdateInstanceCustomHealthStatus(*servicediscovery.UpdateInstanceCustomHealthStatusInput) (*servicediscovery.UpdateInstanceCustomHealthStatusOutput, error)
   167  	UpdateInstanceCustomHealthStatusWithContext(aws.Context, *servicediscovery.UpdateInstanceCustomHealthStatusInput, ...request.Option) (*servicediscovery.UpdateInstanceCustomHealthStatusOutput, error)
   168  	UpdateInstanceCustomHealthStatusRequest(*servicediscovery.UpdateInstanceCustomHealthStatusInput) (*request.Request, *servicediscovery.UpdateInstanceCustomHealthStatusOutput)
   169  
   170  	UpdatePrivateDnsNamespace(*servicediscovery.UpdatePrivateDnsNamespaceInput) (*servicediscovery.UpdatePrivateDnsNamespaceOutput, error)
   171  	UpdatePrivateDnsNamespaceWithContext(aws.Context, *servicediscovery.UpdatePrivateDnsNamespaceInput, ...request.Option) (*servicediscovery.UpdatePrivateDnsNamespaceOutput, error)
   172  	UpdatePrivateDnsNamespaceRequest(*servicediscovery.UpdatePrivateDnsNamespaceInput) (*request.Request, *servicediscovery.UpdatePrivateDnsNamespaceOutput)
   173  
   174  	UpdatePublicDnsNamespace(*servicediscovery.UpdatePublicDnsNamespaceInput) (*servicediscovery.UpdatePublicDnsNamespaceOutput, error)
   175  	UpdatePublicDnsNamespaceWithContext(aws.Context, *servicediscovery.UpdatePublicDnsNamespaceInput, ...request.Option) (*servicediscovery.UpdatePublicDnsNamespaceOutput, error)
   176  	UpdatePublicDnsNamespaceRequest(*servicediscovery.UpdatePublicDnsNamespaceInput) (*request.Request, *servicediscovery.UpdatePublicDnsNamespaceOutput)
   177  
   178  	UpdateService(*servicediscovery.UpdateServiceInput) (*servicediscovery.UpdateServiceOutput, error)
   179  	UpdateServiceWithContext(aws.Context, *servicediscovery.UpdateServiceInput, ...request.Option) (*servicediscovery.UpdateServiceOutput, error)
   180  	UpdateServiceRequest(*servicediscovery.UpdateServiceInput) (*request.Request, *servicediscovery.UpdateServiceOutput)
   181  }
   182  
   183  var _ ServiceDiscoveryAPI = (*servicediscovery.ServiceDiscovery)(nil)