| | 1 | | // Copyright (c) Microsoft Corporation. All rights reserved. |
| | 2 | | // Licensed under the MIT License. |
| | 3 | |
|
| | 4 | | using System.Text.Json; |
| | 5 | |
|
| | 6 | | namespace Azure.Security.KeyVault.Certificates |
| | 7 | | { |
| | 8 | | internal class CertificateOperationUpdateParameters : IJsonSerializable |
| | 9 | | { |
| | 10 | | private const string CancellationRequestedPropertyName = "cancellation_requested"; |
| 2 | 11 | | private static readonly JsonEncodedText s_cancellationRequestedPropertyNameBytes = JsonEncodedText.Encode(Cancel |
| | 12 | |
|
| | 13 | | private readonly bool _cancellationRequested; |
| | 14 | |
|
| 8 | 15 | | public CertificateOperationUpdateParameters(bool cancellationRequested) |
| | 16 | | { |
| 8 | 17 | | _cancellationRequested = cancellationRequested; |
| 8 | 18 | | } |
| | 19 | |
|
| | 20 | | void IJsonSerializable.WriteProperties(Utf8JsonWriter json) |
| | 21 | | { |
| 8 | 22 | | json.WriteBoolean(s_cancellationRequestedPropertyNameBytes, _cancellationRequested); |
| 8 | 23 | | } |
| | 24 | | } |
| | 25 | | } |