| | | 1 | | // Copyright (c) Microsoft Corporation. All rights reserved. |
| | | 2 | | // Licensed under the MIT License. |
| | | 3 | | |
| | | 4 | | // <auto-generated/> |
| | | 5 | | |
| | | 6 | | #nullable disable |
| | | 7 | | |
| | | 8 | | using System; |
| | | 9 | | |
| | | 10 | | namespace Azure.AI.FormRecognizer.Models |
| | | 11 | | { |
| | | 12 | | /// <summary> Information about the extracted key-value pair. </summary> |
| | | 13 | | internal partial class KeyValuePair |
| | | 14 | | { |
| | | 15 | | /// <summary> Initializes a new instance of KeyValuePair. </summary> |
| | | 16 | | /// <param name="key"> Information about the extracted key in a key-value pair. </param> |
| | | 17 | | /// <param name="value"> Information about the extracted value in a key-value pair. </param> |
| | | 18 | | /// <param name="confidence"> Confidence value. </param> |
| | | 19 | | /// <exception cref="ArgumentNullException"> <paramref name="key"/> or <paramref name="value"/> is null. </excep |
| | 0 | 20 | | internal KeyValuePair(KeyValueElement key, KeyValueElement value, float confidence) |
| | | 21 | | { |
| | 0 | 22 | | if (key == null) |
| | | 23 | | { |
| | 0 | 24 | | throw new ArgumentNullException(nameof(key)); |
| | | 25 | | } |
| | 0 | 26 | | if (value == null) |
| | | 27 | | { |
| | 0 | 28 | | throw new ArgumentNullException(nameof(value)); |
| | | 29 | | } |
| | | 30 | | |
| | 0 | 31 | | Key = key; |
| | 0 | 32 | | Value = value; |
| | 0 | 33 | | Confidence = confidence; |
| | 0 | 34 | | } |
| | | 35 | | |
| | | 36 | | /// <summary> Initializes a new instance of KeyValuePair. </summary> |
| | | 37 | | /// <param name="label"> A user defined label for the key/value pair entry. </param> |
| | | 38 | | /// <param name="key"> Information about the extracted key in a key-value pair. </param> |
| | | 39 | | /// <param name="value"> Information about the extracted value in a key-value pair. </param> |
| | | 40 | | /// <param name="confidence"> Confidence value. </param> |
| | 576 | 41 | | internal KeyValuePair(string label, KeyValueElement key, KeyValueElement value, float confidence) |
| | | 42 | | { |
| | 576 | 43 | | Label = label; |
| | 576 | 44 | | Key = key; |
| | 576 | 45 | | Value = value; |
| | 576 | 46 | | Confidence = confidence; |
| | 576 | 47 | | } |
| | | 48 | | |
| | | 49 | | /// <summary> A user defined label for the key/value pair entry. </summary> |
| | 576 | 50 | | public string Label { get; } |
| | | 51 | | /// <summary> Information about the extracted key in a key-value pair. </summary> |
| | 2288 | 52 | | public KeyValueElement Key { get; } |
| | | 53 | | /// <summary> Information about the extracted value in a key-value pair. </summary> |
| | 3232 | 54 | | public KeyValueElement Value { get; } |
| | | 55 | | /// <summary> Confidence value. </summary> |
| | 576 | 56 | | public float Confidence { get; } |
| | | 57 | | } |
| | | 58 | | } |