< Summary

Class:Microsoft.Azure.KeyVault.Models.DeletedKeyBundle
Assembly:Microsoft.Azure.KeyVault
File(s):C:\Git\azure-sdk-for-net\sdk\keyvault\Microsoft.Azure.KeyVault\src\Customized\DeletedKeyBundle.cs
C:\Git\azure-sdk-for-net\sdk\keyvault\Microsoft.Azure.KeyVault\src\Generated\Models\DeletedKeyBundle.cs
Covered lines:5
Uncovered lines:8
Coverable lines:13
Total lines:110
Line coverage:38.4% (5 of 13)
Covered branches:0
Total branches:2
Branch coverage:0% (0 of 2)

Metrics

MethodCyclomatic complexity Line coverage Branch coverage
get_RecoveryId()-100%100%
get_ScheduledPurgeDate()-100%100%
get_DeletedDate()-100%100%
.ctor()-100%100%
.ctor(...)-100%100%
get_RecoveryIdentifier()-0%0%
.ctor()-100%100%
.ctor(...)-0%100%
get_RecoveryId()-100%100%
get_ScheduledPurgeDate()-100%100%
get_DeletedDate()-100%100%

File(s)

C:\Git\azure-sdk-for-net\sdk\keyvault\Microsoft.Azure.KeyVault\src\Customized\DeletedKeyBundle.cs

#LineLine coverage
 1using System;
 2using System.Collections.Generic;
 3using System.Linq;
 4using System.Threading.Tasks;
 5
 6namespace Microsoft.Azure.KeyVault.Models
 7{
 8    public partial class DeletedKeyBundle
 9    {
 10        /// <summary>
 11        /// The identifier of the deleted key object. This is used to recover the key.
 12        /// </summary>
 13        public DeletedKeyIdentifier RecoveryIdentifier
 14        {
 15            get
 16            {
 017                if (!string.IsNullOrWhiteSpace(RecoveryId))
 018                    return new DeletedKeyIdentifier(RecoveryId);
 19                else
 020                    return null;
 21            }
 22        }
 23    }
 24}

C:\Git\azure-sdk-for-net\sdk\keyvault\Microsoft.Azure.KeyVault\src\Generated\Models\DeletedKeyBundle.cs

#LineLine coverage
 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
 11namespace Microsoft.Azure.KeyVault.Models
 12{
 13    using Microsoft.Rest;
 14    using Microsoft.Rest.Serialization;
 15    using Newtonsoft.Json;
 16    using System.Collections;
 17    using System.Collections.Generic;
 18    using System.Linq;
 19
 20    /// <summary>
 21    /// A DeletedKeyBundle consisting of a WebKey plus its Attributes and
 22    /// deletion info
 23    /// </summary>
 24    public partial class DeletedKeyBundle : KeyBundle
 25    {
 26        /// <summary>
 27        /// Initializes a new instance of the DeletedKeyBundle class.
 28        /// </summary>
 2229        public DeletedKeyBundle()
 30        {
 31            CustomInit();
 2232        }
 33
 34        /// <summary>
 35        /// Initializes a new instance of the DeletedKeyBundle class.
 36        /// </summary>
 37        /// <param name="key">The Json web key.</param>
 38        /// <param name="attributes">The key management attributes.</param>
 39        /// <param name="tags">Application specific metadata in the form of
 40        /// key-value pairs.</param>
 41        /// <param name="managed">True if the key's lifetime is managed by key
 42        /// vault. If this is a key backing a certificate, then managed will be
 43        /// true.</param>
 44        /// <param name="recoveryId">The url of the recovery object, used to
 45        /// identify and recover the deleted key.</param>
 46        /// <param name="scheduledPurgeDate">The time when the key is scheduled
 47        /// to be purged, in UTC</param>
 48        /// <param name="deletedDate">The time when the key was deleted, in
 49        /// UTC</param>
 50        public DeletedKeyBundle(Microsoft.Azure.KeyVault.WebKey.JsonWebKey key = default(Microsoft.Azure.KeyVault.WebKey
 051            : base(key, attributes, tags, managed)
 52        {
 053            RecoveryId = recoveryId;
 054            ScheduledPurgeDate = scheduledPurgeDate;
 055            DeletedDate = deletedDate;
 56            CustomInit();
 057        }
 58
 59        /// <summary>
 60        /// An initialization method that performs custom operations like setting defaults
 61        /// </summary>
 62        partial void CustomInit();
 63
 64        /// <summary>
 65        /// Gets or sets the url of the recovery object, used to identify and
 66        /// recover the deleted key.
 67        /// </summary>
 68        [JsonProperty(PropertyName = "recoveryId")]
 2469        public string RecoveryId { get; set; }
 70
 71        /// <summary>
 72        /// Gets the time when the key is scheduled to be purged, in UTC
 73        /// </summary>
 74        [JsonConverter(typeof(UnixTimeJsonConverter))]
 75        [JsonProperty(PropertyName = "scheduledPurgeDate")]
 4476        public System.DateTime? ScheduledPurgeDate { get; private set; }
 77
 78        /// <summary>
 79        /// Gets the time when the key was deleted, in UTC
 80        /// </summary>
 81        [JsonConverter(typeof(UnixTimeJsonConverter))]
 82        [JsonProperty(PropertyName = "deletedDate")]
 4483        public System.DateTime? DeletedDate { get; private set; }
 84
 85    }
 86}