| | 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.Collections; |
| | 15 | | using System.Collections.Generic; |
| | 16 | | using System.Linq; |
| | 17 | |
|
| | 18 | | /// <summary> |
| | 19 | | /// Represents an index action that operates on a document. |
| | 20 | | /// </summary> |
| | 21 | | public partial class IndexAction<T> |
| | 22 | | { |
| | 23 | | /// <summary> |
| | 24 | | /// Initializes a new instance of the IndexAction class. |
| | 25 | | /// </summary> |
| 0 | 26 | | public IndexAction() |
| | 27 | | { |
| | 28 | | CustomInit(); |
| 0 | 29 | | } |
| | 30 | |
|
| | 31 | | /// <summary> |
| | 32 | | /// Initializes a new instance of the IndexAction class. |
| | 33 | | /// </summary> |
| | 34 | | /// <param name="document">The document on which the action will be performed.</param> |
| | 35 | | /// <param name="actionType">The operation to perform on a document in |
| | 36 | | /// an indexing batch. Possible values include: 'upload', 'merge', |
| | 37 | | /// 'mergeOrUpload', 'delete'</param> |
| 27604 | 38 | | public IndexAction(T document = default(T), IndexActionType actionType = default(IndexActionType)) |
| | 39 | | { |
| 27604 | 40 | | Document = document; |
| 27604 | 41 | | ActionType = actionType; |
| | 42 | | CustomInit(); |
| 27604 | 43 | | } |
| | 44 | |
|
| | 45 | | /// <summary> |
| | 46 | | /// An initialization method that performs custom operations like setting defaults |
| | 47 | | /// </summary> |
| | 48 | | partial void CustomInit(); |
| | 49 | |
|
| | 50 | | /// <summary> |
| | 51 | | /// Gets the document on which the action will be performed; Fields other than the key are ignored for delete ac |
| | 52 | | /// </summary> |
| 55332 | 53 | | public T Document { get; set; } |
| | 54 | |
|
| | 55 | | /// <summary> |
| | 56 | | /// Gets or sets the operation to perform on a document in an indexing |
| | 57 | | /// batch. Possible values include: 'upload', 'merge', 'mergeOrUpload', |
| | 58 | | /// 'delete' |
| | 59 | | /// </summary> |
| | 60 | | [JsonProperty(PropertyName = "@search.action")] |
| 55112 | 61 | | public IndexActionType ActionType { get; set; } |
| | 62 | |
|
| | 63 | | } |
| | 64 | | } |