Policy.Autorest/custom/PolicyExemptionUpdate.cs

// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
 
namespace Microsoft.Azure.PowerShell.Cmdlets.Policy.Models
{
    public partial class PolicyExemptionUpdate
    {
        /// <summary>
        /// The resource selectors, exposed with their pre-migration element type
        /// <see cref="IResourceSelectorAutoGenerated"/> (the emitter renamed the element type to
        /// <see cref="IResourceSelector"/>). The generated flattened property is renamed to
        /// <c>ResourceSelectorRaw</c> (see tspconfig.yaml) so this back-compatible accessor owns the
        /// <c>ResourceSelector</c> name. Because <c>List&lt;A&gt;</c> is not assignable to
        /// <c>List&lt;B&gt;</c> even when the element types are compatible, the list is projected;
        /// the underlying elements are the same concrete <see cref="ResourceSelector"/> instances.
        /// </summary>
        public System.Collections.Generic.List<Microsoft.Azure.PowerShell.Cmdlets.Policy.Models.IResourceSelectorAutoGenerated> ResourceSelector
        {
            get
            {
                var __raw = ((Microsoft.Azure.PowerShell.Cmdlets.Policy.Models.IPolicyExemptionUpdatePropertiesInternal)Property).ResourceSelector;
                return __raw == null ? null : System.Linq.Enumerable.ToList(System.Linq.Enumerable.OfType<Microsoft.Azure.PowerShell.Cmdlets.Policy.Models.IResourceSelectorAutoGenerated>(__raw));
            }
            set => ((Microsoft.Azure.PowerShell.Cmdlets.Policy.Models.IPolicyExemptionUpdatePropertiesInternal)Property).ResourceSelector =
                value == null ? null : System.Linq.Enumerable.ToList(System.Linq.Enumerable.OfType<Microsoft.Azure.PowerShell.Cmdlets.Policy.Models.IResourceSelector>(value));
        }
    }
 
    public partial interface IPolicyExemptionUpdate
    {
        /// <summary>
        /// The resource selectors. Restored to their pre-migration element type
        /// <see cref="IResourceSelectorAutoGenerated"/> (renamed to <see cref="IResourceSelector"/>).
        /// </summary>
        System.Collections.Generic.List<Microsoft.Azure.PowerShell.Cmdlets.Policy.Models.IResourceSelectorAutoGenerated> ResourceSelector { get; set; }
    }
}