| | 1 | | // <auto-generated> |
| | 2 | | // Code generated by Microsoft (R) AutoRest Code Generator. |
| | 3 | | // Changes may cause incorrect behavior and will be lost if the code is |
| | 4 | | // regenerated. |
| | 5 | | // </auto-generated> |
| | 6 | |
|
| | 7 | | namespace Microsoft.Azure.CognitiveServices.Search.VisualSearch.Models |
| | 8 | | { |
| | 9 | | using Newtonsoft.Json; |
| | 10 | | using System.Collections; |
| | 11 | | using System.Collections.Generic; |
| | 12 | | using System.Linq; |
| | 13 | |
|
| | 14 | | /// <summary> |
| | 15 | | /// Defines an image. |
| | 16 | | /// </summary> |
| | 17 | | public partial class ImageObject : MediaObject |
| | 18 | | { |
| | 19 | | /// <summary> |
| | 20 | | /// Initializes a new instance of the ImageObject class. |
| | 21 | | /// </summary> |
| 704 | 22 | | public ImageObject() |
| | 23 | | { |
| | 24 | | CustomInit(); |
| 704 | 25 | | } |
| | 26 | |
|
| | 27 | | /// <summary> |
| | 28 | | /// Initializes a new instance of the ImageObject class. |
| | 29 | | /// </summary> |
| | 30 | | /// <param name="id">A String identifier.</param> |
| | 31 | | /// <param name="readLink">The URL that returns this resource. To use |
| | 32 | | /// the URL, append query parameters as appropriate and include the |
| | 33 | | /// Ocp-Apim-Subscription-Key header.</param> |
| | 34 | | /// <param name="webSearchUrl">The URL to Bing's search result for this |
| | 35 | | /// item.</param> |
| | 36 | | /// <param name="name">The name of the thing represented by this |
| | 37 | | /// object.</param> |
| | 38 | | /// <param name="url">The URL to get more information about the thing |
| | 39 | | /// represented by this object.</param> |
| | 40 | | /// <param name="image">An image of the item.</param> |
| | 41 | | /// <param name="description">A short description of the item.</param> |
| | 42 | | /// <param name="alternateName">An alias for the item.</param> |
| | 43 | | /// <param name="bingId">An ID that uniquely identifies this |
| | 44 | | /// item.</param> |
| | 45 | | /// <param name="thumbnailUrl">The URL to a thumbnail of the |
| | 46 | | /// item.</param> |
| | 47 | | /// <param name="provider">The source of the creative work.</param> |
| | 48 | | /// <param name="datePublished">The date on which the CreativeWork was |
| | 49 | | /// published.</param> |
| | 50 | | /// <param name="text">Text content of this creative work.</param> |
| | 51 | | /// <param name="contentUrl">Original URL to retrieve the source (file) |
| | 52 | | /// for the media object (e.g., the source URL for the image).</param> |
| | 53 | | /// <param name="hostPageUrl">URL of the page that hosts the media |
| | 54 | | /// object.</param> |
| | 55 | | /// <param name="contentSize">Size of the media object content. Use |
| | 56 | | /// format "value unit" (e.g., "1024 B").</param> |
| | 57 | | /// <param name="encodingFormat">Encoding format (e.g., png, gif, jpeg, |
| | 58 | | /// etc).</param> |
| | 59 | | /// <param name="hostPageDisplayUrl">Display URL of the page that hosts |
| | 60 | | /// the media object.</param> |
| | 61 | | /// <param name="width">The width of the media object, in |
| | 62 | | /// pixels.</param> |
| | 63 | | /// <param name="height">The height of the media object, in |
| | 64 | | /// pixels.</param> |
| | 65 | | /// <param name="thumbnail">The URL to a thumbnail of the |
| | 66 | | /// image.</param> |
| | 67 | | /// <param name="imageInsightsToken">The token that you use in a |
| | 68 | | /// subsequent call to Visual Search API to get additional information |
| | 69 | | /// about the image. For information about using this token, see the |
| | 70 | | /// imageInsightsToken field inside the knowledgeRequest request |
| | 71 | | /// parameter.</param> |
| | 72 | | /// <param name="insightsMetadata">A count of the number of websites |
| | 73 | | /// where you can shop or perform other actions related to the image. |
| | 74 | | /// For example, if the image is of an apple pie, this object includes |
| | 75 | | /// a count of the number of websites where you can buy an apple pie. |
| | 76 | | /// To indicate the number of offers in your UX, include badging such |
| | 77 | | /// as a shopping cart icon that contains the count. When the user |
| | 78 | | /// clicks on the icon, use imageInisghtsToken in a subsequent Visual |
| | 79 | | /// Search API call to get the list of shopping websites.</param> |
| | 80 | | /// <param name="imageId">Unique Id for the image.</param> |
| | 81 | | /// <param name="accentColor">A three-byte hexadecimal number that |
| | 82 | | /// represents the color that dominates the image. Use the color as the |
| | 83 | | /// temporary background in your client until the image is |
| | 84 | | /// loaded.</param> |
| | 85 | | /// <param name="visualWords">For interal use only.</param> |
| | 86 | | public ImageObject(string id = default(string), string readLink = default(string), string webSearchUrl = default |
| 0 | 87 | | : base(id, readLink, webSearchUrl, name, url, image, description, alternateName, bingId, thumbnailUrl, provi |
| | 88 | | { |
| 0 | 89 | | Thumbnail = thumbnail; |
| 0 | 90 | | ImageInsightsToken = imageInsightsToken; |
| 0 | 91 | | InsightsMetadata = insightsMetadata; |
| 0 | 92 | | ImageId = imageId; |
| 0 | 93 | | AccentColor = accentColor; |
| 0 | 94 | | VisualWords = visualWords; |
| | 95 | | CustomInit(); |
| 0 | 96 | | } |
| | 97 | |
|
| | 98 | | /// <summary> |
| | 99 | | /// An initialization method that performs custom operations like setting defaults |
| | 100 | | /// </summary> |
| | 101 | | partial void CustomInit(); |
| | 102 | |
|
| | 103 | | /// <summary> |
| | 104 | | /// Gets the URL to a thumbnail of the image. |
| | 105 | | /// </summary> |
| | 106 | | [JsonProperty(PropertyName = "thumbnail")] |
| 0 | 107 | | public ImageObject Thumbnail { get; private set; } |
| | 108 | |
|
| | 109 | | /// <summary> |
| | 110 | | /// Gets the token that you use in a subsequent call to Visual Search |
| | 111 | | /// API to get additional information about the image. For information |
| | 112 | | /// about using this token, see the imageInsightsToken field inside the |
| | 113 | | /// knowledgeRequest request parameter. |
| | 114 | | /// </summary> |
| | 115 | | [JsonProperty(PropertyName = "imageInsightsToken")] |
| 0 | 116 | | public string ImageInsightsToken { get; private set; } |
| | 117 | |
|
| | 118 | | /// <summary> |
| | 119 | | /// Gets a count of the number of websites where you can shop or |
| | 120 | | /// perform other actions related to the image. For example, if the |
| | 121 | | /// image is of an apple pie, this object includes a count of the |
| | 122 | | /// number of websites where you can buy an apple pie. To indicate the |
| | 123 | | /// number of offers in your UX, include badging such as a shopping |
| | 124 | | /// cart icon that contains the count. When the user clicks on the |
| | 125 | | /// icon, use imageInisghtsToken in a subsequent Visual Search API call |
| | 126 | | /// to get the list of shopping websites. |
| | 127 | | /// </summary> |
| | 128 | | [JsonProperty(PropertyName = "insightsMetadata")] |
| 0 | 129 | | public ImagesImageMetadata InsightsMetadata { get; private set; } |
| | 130 | |
|
| | 131 | | /// <summary> |
| | 132 | | /// Gets unique Id for the image. |
| | 133 | | /// </summary> |
| | 134 | | [JsonProperty(PropertyName = "imageId")] |
| 0 | 135 | | public string ImageId { get; private set; } |
| | 136 | |
|
| | 137 | | /// <summary> |
| | 138 | | /// Gets a three-byte hexadecimal number that represents the color that |
| | 139 | | /// dominates the image. Use the color as the temporary background in |
| | 140 | | /// your client until the image is loaded. |
| | 141 | | /// </summary> |
| | 142 | | [JsonProperty(PropertyName = "accentColor")] |
| 0 | 143 | | public string AccentColor { get; private set; } |
| | 144 | |
|
| | 145 | | /// <summary> |
| | 146 | | /// Gets for interal use only. |
| | 147 | | /// </summary> |
| | 148 | | [JsonProperty(PropertyName = "visualWords")] |
| 0 | 149 | | public string VisualWords { get; private set; } |
| | 150 | |
|
| | 151 | | } |
| | 152 | | } |