| | 1 | | // <auto-generated> |
| | 2 | | // Copyright (c) Microsoft Corporation. All rights reserved. |
| | 3 | | // Licensed under the MIT License. See License.txt in the project root for |
| | 4 | | // license information. |
| | 5 | | // |
| | 6 | | // Code generated by Microsoft (R) AutoRest Code Generator. |
| | 7 | | // Changes may cause incorrect behavior and will be lost if the code is |
| | 8 | | // regenerated. |
| | 9 | | // </auto-generated> |
| | 10 | |
|
| | 11 | | namespace Microsoft.Azure.Search.Models |
| | 12 | | { |
| | 13 | | using Newtonsoft.Json; |
| | 14 | | using System.Linq; |
| | 15 | |
|
| | 16 | | /// <summary> |
| | 17 | | /// Status of an indexing operation for a single document. |
| | 18 | | /// </summary> |
| | 19 | | public partial class IndexingResult |
| | 20 | | { |
| | 21 | | /// <summary> |
| | 22 | | /// Initializes a new instance of the IndexingResult class. |
| | 23 | | /// </summary> |
| 27506 | 24 | | public IndexingResult() |
| | 25 | | { |
| | 26 | | CustomInit(); |
| 27506 | 27 | | } |
| | 28 | |
|
| | 29 | | /// <summary> |
| | 30 | | /// Initializes a new instance of the IndexingResult class. |
| | 31 | | /// </summary> |
| | 32 | | /// <param name="key">The key of a document that was in the indexing |
| | 33 | | /// request.</param> |
| | 34 | | /// <param name="errorMessage">The error message explaining why the |
| | 35 | | /// indexing operation failed for the document identified by the key; |
| | 36 | | /// null if indexing succeeded.</param> |
| | 37 | | /// <param name="succeeded">A value indicating whether the indexing |
| | 38 | | /// operation succeeded for the document identified by the key.</param> |
| | 39 | | /// <param name="statusCode">The status code of the indexing operation. |
| | 40 | | /// Possible values include: 200 for a successful update or delete, 201 |
| | 41 | | /// for successful document creation, 400 for a malformed input |
| | 42 | | /// document, 404 for document not found, 409 for a version conflict, |
| | 43 | | /// 422 when the index is temporarily unavailable, or 503 for when the |
| | 44 | | /// service is too busy.</param> |
| 48 | 45 | | public IndexingResult(string key = default(string), string errorMessage = default(string), bool succeeded = defa |
| | 46 | | { |
| 48 | 47 | | Key = key; |
| 48 | 48 | | ErrorMessage = errorMessage; |
| 48 | 49 | | Succeeded = succeeded; |
| 48 | 50 | | StatusCode = statusCode; |
| | 51 | | CustomInit(); |
| 48 | 52 | | } |
| | 53 | |
|
| | 54 | | /// <summary> |
| | 55 | | /// An initialization method that performs custom operations like setting defaults |
| | 56 | | /// </summary> |
| | 57 | | partial void CustomInit(); |
| | 58 | |
|
| | 59 | | /// <summary> |
| | 60 | | /// Gets the key of a document that was in the indexing request. |
| | 61 | | /// </summary> |
| | 62 | | [JsonProperty(PropertyName = "key")] |
| 27740 | 63 | | public string Key { get; private set; } |
| | 64 | |
|
| | 65 | | /// <summary> |
| | 66 | | /// Gets the error message explaining why the indexing operation failed |
| | 67 | | /// for the document identified by the key; null if indexing succeeded. |
| | 68 | | /// </summary> |
| | 69 | | [JsonProperty(PropertyName = "errorMessage")] |
| 112 | 70 | | public string ErrorMessage { get; private set; } |
| | 71 | |
|
| | 72 | | /// <summary> |
| | 73 | | /// Gets a value indicating whether the indexing operation succeeded |
| | 74 | | /// for the document identified by the key. |
| | 75 | | /// </summary> |
| | 76 | | [JsonProperty(PropertyName = "status")] |
| 27768 | 77 | | public bool Succeeded { get; private set; } |
| | 78 | |
|
| | 79 | | /// <summary> |
| | 80 | | /// Gets the status code of the indexing operation. Possible values |
| | 81 | | /// include: 200 for a successful update or delete, 201 for successful |
| | 82 | | /// document creation, 400 for a malformed input document, 404 for |
| | 83 | | /// document not found, 409 for a version conflict, 422 when the index |
| | 84 | | /// is temporarily unavailable, or 503 for when the service is too |
| | 85 | | /// busy. |
| | 86 | | /// </summary> |
| | 87 | | [JsonProperty(PropertyName = "statusCode")] |
| 27706 | 88 | | public int StatusCode { get; private set; } |
| | 89 | |
|
| | 90 | | } |
| | 91 | | } |