...

Source file src/github.com/Azure/azure-sdk-for-go/services/preview/cognitiveservices/v1.0/visualsearch/client.go

Documentation: github.com/Azure/azure-sdk-for-go/services/preview/cognitiveservices/v1.0/visualsearch

     1  // Package visualsearch implements the Azure ARM Visualsearch service API version 1.0.
     2  //
     3  // Visual Search API lets you discover insights about an image such as visually similar images, shopping sources, and
     4  // related searches. The API can also perform text recognition, identify entities (people, places, things), return
     5  // other topical content for the user to explore, and more. For more information, see [Visual Search
     6  // Overview](https://docs.microsoft.com/azure/cognitive-services/bing-visual-search/overview).  **NOTE:** To comply
     7  // with the new EU Copyright Directive in France, the Bing Visual Search API must omit some content from certain EU
     8  // News sources for French users. The removed content may include thumbnail images and videos, video previews, and
     9  // snippets which accompany search results from these sources. As a consequence, the Bing APIs may serve fewer results
    10  // with thumbnail images and videos, video previews, and snippets to French users.
    11  package visualsearch
    12  
    13  // Copyright (c) Microsoft Corporation. All rights reserved.
    14  // Licensed under the MIT License. See License.txt in the project root for license information.
    15  //
    16  // Code generated by Microsoft (R) AutoRest Code Generator.
    17  // Changes may cause incorrect behavior and will be lost if the code is regenerated.
    18  
    19  import (
    20  	"github.com/Azure/go-autorest/autorest"
    21  )
    22  
    23  const (
    24  	// DefaultEndpoint is the default value for endpoint
    25  	DefaultEndpoint = "https://api.cognitive.microsoft.com"
    26  )
    27  
    28  // BaseClient is the base client for Visualsearch.
    29  type BaseClient struct {
    30  	autorest.Client
    31  	Endpoint string
    32  }
    33  
    34  // New creates an instance of the BaseClient client.
    35  func New() BaseClient {
    36  	return NewWithoutDefaults(DefaultEndpoint)
    37  }
    38  
    39  // NewWithoutDefaults creates an instance of the BaseClient client.
    40  func NewWithoutDefaults(endpoint string) BaseClient {
    41  	return BaseClient{
    42  		Client:   autorest.NewClientWithUserAgent(UserAgent()),
    43  		Endpoint: endpoint,
    44  	}
    45  }
    46  

View as plain text