File: CacheParameter.cs
Web Access
Project: src\src\sdk\src\TemplateEngine\Microsoft.TemplateEngine.Utils\Microsoft.TemplateEngine.Utils.csproj (Microsoft.TemplateEngine.Utils)
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.

using Microsoft.TemplateEngine.Abstractions;

namespace Microsoft.TemplateEngine.Utils
{
    [Obsolete("Use ITemplateParameter / TemplateParameter instead.")]
    public class CacheParameter : ICacheParameter, IAllowDefaultIfOptionWithoutValue
    {
        public string? DataType { get; set; }

        public string? DefaultValue { get; set; }

        public string? DisplayName { get; set; }

        public string? Description { get; set; }

        public string? DefaultIfOptionWithoutValue { get; set; }

        public bool ShouldSerializeDefaultIfOptionWithoutValue()
        {
            return !string.IsNullOrEmpty(DefaultIfOptionWithoutValue);
        }
    }
}