| | 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.Linq; |
| | 11 | |
|
| | 12 | | /// <summary> |
| | 13 | | /// Defines a 2D point with X and Y coordinates. |
| | 14 | | /// </summary> |
| | 15 | | public partial class Point2D : StructuredValue |
| | 16 | | { |
| | 17 | | /// <summary> |
| | 18 | | /// Initializes a new instance of the Point2D class. |
| | 19 | | /// </summary> |
| 224 | 20 | | public Point2D() |
| | 21 | | { |
| | 22 | | CustomInit(); |
| 224 | 23 | | } |
| | 24 | |
|
| | 25 | | /// <summary> |
| | 26 | | /// Initializes a new instance of the Point2D class. |
| | 27 | | /// </summary> |
| | 28 | | /// <param name="x">The x-coordinate of the point.</param> |
| | 29 | | /// <param name="y">The y-coordinate of the point.</param> |
| | 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 | | public Point2D(double x, double y, string id = default(string), string readLink = default(string), string webSea |
| 0 | 46 | | : base(id, readLink, webSearchUrl, name, url, image, description, alternateName, bingId) |
| | 47 | | { |
| 0 | 48 | | X = x; |
| 0 | 49 | | Y = y; |
| | 50 | | CustomInit(); |
| 0 | 51 | | } |
| | 52 | |
|
| | 53 | | /// <summary> |
| | 54 | | /// An initialization method that performs custom operations like setting defaults |
| | 55 | | /// </summary> |
| | 56 | | partial void CustomInit(); |
| | 57 | |
|
| | 58 | | /// <summary> |
| | 59 | | /// Gets or sets the x-coordinate of the point. |
| | 60 | | /// </summary> |
| | 61 | | [JsonProperty(PropertyName = "x")] |
| 0 | 62 | | public double X { get; set; } |
| | 63 | |
|
| | 64 | | /// <summary> |
| | 65 | | /// Gets or sets the y-coordinate of the point. |
| | 66 | | /// </summary> |
| | 67 | | [JsonProperty(PropertyName = "y")] |
| 0 | 68 | | public double Y { get; set; } |
| | 69 | |
|
| | 70 | | /// <summary> |
| | 71 | | /// Validate the object. |
| | 72 | | /// </summary> |
| | 73 | | /// <exception cref="Rest.ValidationException"> |
| | 74 | | /// Thrown if validation fails |
| | 75 | | /// </exception> |
| | 76 | | public virtual void Validate() |
| | 77 | | { |
| | 78 | | //Nothing to validate |
| 0 | 79 | | } |
| | 80 | | } |
| | 81 | | } |