< Summary

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

Metrics

MethodCyclomatic complexity Line coverage Branch coverage
.ctor()-0%100%
.ctor(...)-0%100%
get_X509Certificates()-0%100%
get_CertificateAttributes()-0%100%
get_Tags()-0%100%
Validate()-0%0%

File(s)

C:\Git\azure-sdk-for-net\sdk\keyvault\Microsoft.Azure.KeyVault\src\Generated\Models\CertificateMergeParameters.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 Newtonsoft.Json;
 15    using System.Collections;
 16    using System.Collections.Generic;
 17    using System.Linq;
 18
 19    /// <summary>
 20    /// The certificate merge parameters
 21    /// </summary>
 22    public partial class CertificateMergeParameters
 23    {
 24        /// <summary>
 25        /// Initializes a new instance of the CertificateMergeParameters class.
 26        /// </summary>
 027        public CertificateMergeParameters()
 28        {
 29            CustomInit();
 030        }
 31
 32        /// <summary>
 33        /// Initializes a new instance of the CertificateMergeParameters class.
 34        /// </summary>
 35        /// <param name="x509Certificates">The certificate or the certificate
 36        /// chain to merge.</param>
 37        /// <param name="certificateAttributes">The attributes of the
 38        /// certificate (optional).</param>
 39        /// <param name="tags">Application specific metadata in the form of
 40        /// key-value pairs.</param>
 041        public CertificateMergeParameters(IList<byte[]> x509Certificates, CertificateAttributes certificateAttributes = 
 42        {
 043            X509Certificates = x509Certificates;
 044            CertificateAttributes = certificateAttributes;
 045            Tags = tags;
 46            CustomInit();
 047        }
 48
 49        /// <summary>
 50        /// An initialization method that performs custom operations like setting defaults
 51        /// </summary>
 52        partial void CustomInit();
 53
 54        /// <summary>
 55        /// Gets or sets the certificate or the certificate chain to merge.
 56        /// </summary>
 57        [JsonProperty(PropertyName = "x5c")]
 058        public IList<byte[]> X509Certificates { get; set; }
 59
 60        /// <summary>
 61        /// Gets or sets the attributes of the certificate (optional).
 62        /// </summary>
 63        [JsonProperty(PropertyName = "attributes")]
 064        public CertificateAttributes CertificateAttributes { get; set; }
 65
 66        /// <summary>
 67        /// Gets or sets application specific metadata in the form of key-value
 68        /// pairs.
 69        /// </summary>
 70        [JsonProperty(PropertyName = "tags")]
 071        public IDictionary<string, string> Tags { get; set; }
 72
 73        /// <summary>
 74        /// Validate the object.
 75        /// </summary>
 76        /// <exception cref="ValidationException">
 77        /// Thrown if validation fails
 78        /// </exception>
 79        public virtual void Validate()
 80        {
 081            if (X509Certificates == null)
 82            {
 083                throw new ValidationException(ValidationRules.CannotBeNull, "X509Certificates");
 84            }
 085        }
 86    }
 87}