generated/api/Models/CreateServerPlan.PowerShell.cs

// Code generated by Microsoft (R) AutoRest Code Generator (autorest: 3.8.4, generator: @autorest/powershell@3.0.415)
// Changes may cause incorrect behavior and will be lost if the code is regenerated.

namespace Commvault.Powershell.Models
{
    using Commvault.Powershell.Runtime.PowerShell;

    [System.ComponentModel.TypeConverter(typeof(CreateServerPlanTypeConverter))]
    public partial class CreateServerPlan
    {

        /// <summary>
        /// <c>AfterDeserializeDictionary</c> will be called after the deserialization has finished, allowing customization of the
        /// object before it is returned. Implement this method in a partial class to enable this behavior
        /// </summary>
        /// <param name="content">The global::System.Collections.IDictionary content that should be used.</param>

        partial void AfterDeserializeDictionary(global::System.Collections.IDictionary content);

        /// <summary>
        /// <c>AfterDeserializePSObject</c> will be called after the deserialization has finished, allowing customization of the object
        /// before it is returned. Implement this method in a partial class to enable this behavior
        /// </summary>
        /// <param name="content">The global::System.Management.Automation.PSObject content that should be used.</param>

        partial void AfterDeserializePSObject(global::System.Management.Automation.PSObject content);

        /// <summary>
        /// <c>BeforeDeserializeDictionary</c> will be called before the deserialization has commenced, allowing complete customization
        /// of the object before it is deserialized.
        /// If you wish to disable the default deserialization entirely, return <c>true</c> in the <see "returnNow" /> output parameter.
        /// Implement this method in a partial class to enable this behavior.
        /// </summary>
        /// <param name="content">The global::System.Collections.IDictionary content that should be used.</param>
        /// <param name="returnNow">Determines if the rest of the serialization should be processed, or if the method should return
        /// instantly.</param>

        partial void BeforeDeserializeDictionary(global::System.Collections.IDictionary content, ref bool returnNow);

        /// <summary>
        /// <c>BeforeDeserializePSObject</c> will be called before the deserialization has commenced, allowing complete customization
        /// of the object before it is deserialized.
        /// If you wish to disable the default deserialization entirely, return <c>true</c> in the <see "returnNow" /> output parameter.
        /// Implement this method in a partial class to enable this behavior.
        /// </summary>
        /// <param name="content">The global::System.Management.Automation.PSObject content that should be used.</param>
        /// <param name="returnNow">Determines if the rest of the serialization should be processed, or if the method should return
        /// instantly.</param>

        partial void BeforeDeserializePSObject(global::System.Management.Automation.PSObject content, ref bool returnNow);

        /// <summary>
        /// Deserializes a <see cref="global::System.Collections.IDictionary" /> into a new instance of <see cref="Commvault.Powershell.Models.CreateServerPlan"
        /// />.
        /// </summary>
        /// <param name="content">The global::System.Collections.IDictionary content that should be used.</param>
        internal CreateServerPlan(global::System.Collections.IDictionary content)
        {
            bool returnNow = false;
            BeforeDeserializeDictionary(content, ref returnNow);
            if (returnNow)
            {
                return;
            }
            // actually deserialize
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).Rpo = (Commvault.Powershell.Models.IServerBackupPlanRpo) content.GetValueForProperty("Rpo",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).Rpo, Commvault.Powershell.Models.ServerBackupPlanRpoTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContent = (Commvault.Powershell.Models.IPlanContent) content.GetValueForProperty("BackupContent",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContent, Commvault.Powershell.Models.PlanContentTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).SnapshotOptions = (Commvault.Powershell.Models.ICreatePlanSnapshotOptions) content.GetValueForProperty("SnapshotOptions",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).SnapshotOptions, Commvault.Powershell.Models.CreatePlanSnapshotOptionsTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).DatabaseOptions = (Commvault.Powershell.Models.IServerPlanDatabaseOptions) content.GetValueForProperty("DatabaseOptions",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).DatabaseOptions, Commvault.Powershell.Models.ServerPlanDatabaseOptionsTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).OverrideRestrictions = (Commvault.Powershell.Models.IPlanOverrideSettings) content.GetValueForProperty("OverrideRestrictions",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).OverrideRestrictions, Commvault.Powershell.Models.PlanOverrideSettingsTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).ParentPlan = (Commvault.Powershell.Models.IIdName) content.GetValueForProperty("ParentPlan",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).ParentPlan, Commvault.Powershell.Models.IdNameTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).PlanName = (string) content.GetValueForProperty("PlanName",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).PlanName, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupDestinations = (Commvault.Powershell.Models.ICreatePlanBackupDestination[]) content.GetValueForProperty("BackupDestinations",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupDestinations, __y => TypeConverterExtensions.SelectToArray<Commvault.Powershell.Models.ICreatePlanBackupDestination>(__y, Commvault.Powershell.Models.CreatePlanBackupDestinationTypeConverter.ConvertFrom));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).AllowPlanOverride = (bool?) content.GetValueForProperty("AllowPlanOverride",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).AllowPlanOverride, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).RpoBackupFrequency = (Commvault.Powershell.Models.IPlanSchedules) content.GetValueForProperty("RpoBackupFrequency",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).RpoBackupFrequency, Commvault.Powershell.Models.PlanSchedulesTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).RpoBackupWindow = (Commvault.Powershell.Models.IDayAndTime[]) content.GetValueForProperty("RpoBackupWindow",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).RpoBackupWindow, __y => TypeConverterExtensions.SelectToArray<Commvault.Powershell.Models.IDayAndTime>(__y, Commvault.Powershell.Models.DayAndTimeTypeConverter.ConvertFrom));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).RpoFullBackupWindow = (Commvault.Powershell.Models.IDayAndTime[]) content.GetValueForProperty("RpoFullBackupWindow",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).RpoFullBackupWindow, __y => TypeConverterExtensions.SelectToArray<Commvault.Powershell.Models.IDayAndTime>(__y, Commvault.Powershell.Models.DayAndTimeTypeConverter.ConvertFrom));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentWindowsIncludedPaths = (string[]) content.GetValueForProperty("BackupContentWindowsIncludedPaths",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentWindowsIncludedPaths, __y => TypeConverterExtensions.SelectToArray<string>(__y, global::System.Convert.ToString));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentWindowsExcludedPaths = (string[]) content.GetValueForProperty("BackupContentWindowsExcludedPaths",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentWindowsExcludedPaths, __y => TypeConverterExtensions.SelectToArray<string>(__y, global::System.Convert.ToString));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentBackupSystemState = (bool?) content.GetValueForProperty("BackupContentBackupSystemState",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentBackupSystemState, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentBackupSystemStateOnlyWithFullBackup = (bool?) content.GetValueForProperty("BackupContentBackupSystemStateOnlyWithFullBackup",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentBackupSystemStateOnlyWithFullBackup, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentUseVssForSystemState = (bool?) content.GetValueForProperty("BackupContentUseVssForSystemState",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentUseVssForSystemState, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentMacIncludedPaths = (string[]) content.GetValueForProperty("BackupContentMacIncludedPaths",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentMacIncludedPaths, __y => TypeConverterExtensions.SelectToArray<string>(__y, global::System.Convert.ToString));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentMacExcludedPaths = (string[]) content.GetValueForProperty("BackupContentMacExcludedPaths",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentMacExcludedPaths, __y => TypeConverterExtensions.SelectToArray<string>(__y, global::System.Convert.ToString));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentUnixIncludedPaths = (string[]) content.GetValueForProperty("BackupContentUnixIncludedPaths",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentUnixIncludedPaths, __y => TypeConverterExtensions.SelectToArray<string>(__y, global::System.Convert.ToString));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentUnixExcludedPaths = (string[]) content.GetValueForProperty("BackupContentUnixExcludedPaths",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentUnixExcludedPaths, __y => TypeConverterExtensions.SelectToArray<string>(__y, global::System.Convert.ToString));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).SnapshotOptionSnapRecoveryPoints = (long?) content.GetValueForProperty("SnapshotOptionSnapRecoveryPoints",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).SnapshotOptionSnapRecoveryPoints, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).SnapshotOptionRetentionPeriodDays = (long?) content.GetValueForProperty("SnapshotOptionRetentionPeriodDays",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).SnapshotOptionRetentionPeriodDays, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).SnapshotOptionEnableBackupCopy = (bool?) content.GetValueForProperty("SnapshotOptionEnableBackupCopy",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).SnapshotOptionEnableBackupCopy, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).SnapshotOptionBackupCopyRpoMins = (long?) content.GetValueForProperty("SnapshotOptionBackupCopyRpoMins",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).SnapshotOptionBackupCopyRpoMins, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).DatabaseOptionLogBackupRpoMins = (long?) content.GetValueForProperty("DatabaseOptionLogBackupRpoMins",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).DatabaseOptionLogBackupRpoMins, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).DatabaseOptionUseDiskCacheForLogBackups = (bool?) content.GetValueForProperty("DatabaseOptionUseDiskCacheForLogBackups",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).DatabaseOptionUseDiskCacheForLogBackups, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).DatabaseOptionCommitFrequencyInHours = (long?) content.GetValueForProperty("DatabaseOptionCommitFrequencyInHours",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).DatabaseOptionCommitFrequencyInHours, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).OverrideRestrictionBackupContent = (string) content.GetValueForProperty("OverrideRestrictionBackupContent",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).OverrideRestrictionBackupContent, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).OverrideRestrictionStoragePool = (string) content.GetValueForProperty("OverrideRestrictionStoragePool",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).OverrideRestrictionStoragePool, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).OverrideRestrictionRpo = (string) content.GetValueForProperty("OverrideRestrictionRpo",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).OverrideRestrictionRpo, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).ParentPlanId = (long?) content.GetValueForProperty("ParentPlanId",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).ParentPlanId, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).ParentPlanName = (string) content.GetValueForProperty("ParentPlanName",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).ParentPlanName, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupFrequencySchedules = (Commvault.Powershell.Models.IPlanSchedule[]) content.GetValueForProperty("BackupFrequencySchedules",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupFrequencySchedules, __y => TypeConverterExtensions.SelectToArray<Commvault.Powershell.Models.IPlanSchedule>(__y, Commvault.Powershell.Models.PlanScheduleTypeConverter.ConvertFrom));
            AfterDeserializeDictionary(content);
        }

        /// <summary>
        /// Deserializes a <see cref="global::System.Management.Automation.PSObject" /> into a new instance of <see cref="Commvault.Powershell.Models.CreateServerPlan"
        /// />.
        /// </summary>
        /// <param name="content">The global::System.Management.Automation.PSObject content that should be used.</param>
        internal CreateServerPlan(global::System.Management.Automation.PSObject content)
        {
            bool returnNow = false;
            BeforeDeserializePSObject(content, ref returnNow);
            if (returnNow)
            {
                return;
            }
            // actually deserialize
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).Rpo = (Commvault.Powershell.Models.IServerBackupPlanRpo) content.GetValueForProperty("Rpo",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).Rpo, Commvault.Powershell.Models.ServerBackupPlanRpoTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContent = (Commvault.Powershell.Models.IPlanContent) content.GetValueForProperty("BackupContent",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContent, Commvault.Powershell.Models.PlanContentTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).SnapshotOptions = (Commvault.Powershell.Models.ICreatePlanSnapshotOptions) content.GetValueForProperty("SnapshotOptions",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).SnapshotOptions, Commvault.Powershell.Models.CreatePlanSnapshotOptionsTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).DatabaseOptions = (Commvault.Powershell.Models.IServerPlanDatabaseOptions) content.GetValueForProperty("DatabaseOptions",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).DatabaseOptions, Commvault.Powershell.Models.ServerPlanDatabaseOptionsTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).OverrideRestrictions = (Commvault.Powershell.Models.IPlanOverrideSettings) content.GetValueForProperty("OverrideRestrictions",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).OverrideRestrictions, Commvault.Powershell.Models.PlanOverrideSettingsTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).ParentPlan = (Commvault.Powershell.Models.IIdName) content.GetValueForProperty("ParentPlan",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).ParentPlan, Commvault.Powershell.Models.IdNameTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).PlanName = (string) content.GetValueForProperty("PlanName",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).PlanName, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupDestinations = (Commvault.Powershell.Models.ICreatePlanBackupDestination[]) content.GetValueForProperty("BackupDestinations",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupDestinations, __y => TypeConverterExtensions.SelectToArray<Commvault.Powershell.Models.ICreatePlanBackupDestination>(__y, Commvault.Powershell.Models.CreatePlanBackupDestinationTypeConverter.ConvertFrom));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).AllowPlanOverride = (bool?) content.GetValueForProperty("AllowPlanOverride",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).AllowPlanOverride, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).RpoBackupFrequency = (Commvault.Powershell.Models.IPlanSchedules) content.GetValueForProperty("RpoBackupFrequency",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).RpoBackupFrequency, Commvault.Powershell.Models.PlanSchedulesTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).RpoBackupWindow = (Commvault.Powershell.Models.IDayAndTime[]) content.GetValueForProperty("RpoBackupWindow",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).RpoBackupWindow, __y => TypeConverterExtensions.SelectToArray<Commvault.Powershell.Models.IDayAndTime>(__y, Commvault.Powershell.Models.DayAndTimeTypeConverter.ConvertFrom));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).RpoFullBackupWindow = (Commvault.Powershell.Models.IDayAndTime[]) content.GetValueForProperty("RpoFullBackupWindow",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).RpoFullBackupWindow, __y => TypeConverterExtensions.SelectToArray<Commvault.Powershell.Models.IDayAndTime>(__y, Commvault.Powershell.Models.DayAndTimeTypeConverter.ConvertFrom));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentWindowsIncludedPaths = (string[]) content.GetValueForProperty("BackupContentWindowsIncludedPaths",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentWindowsIncludedPaths, __y => TypeConverterExtensions.SelectToArray<string>(__y, global::System.Convert.ToString));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentWindowsExcludedPaths = (string[]) content.GetValueForProperty("BackupContentWindowsExcludedPaths",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentWindowsExcludedPaths, __y => TypeConverterExtensions.SelectToArray<string>(__y, global::System.Convert.ToString));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentBackupSystemState = (bool?) content.GetValueForProperty("BackupContentBackupSystemState",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentBackupSystemState, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentBackupSystemStateOnlyWithFullBackup = (bool?) content.GetValueForProperty("BackupContentBackupSystemStateOnlyWithFullBackup",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentBackupSystemStateOnlyWithFullBackup, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentUseVssForSystemState = (bool?) content.GetValueForProperty("BackupContentUseVssForSystemState",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentUseVssForSystemState, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentMacIncludedPaths = (string[]) content.GetValueForProperty("BackupContentMacIncludedPaths",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentMacIncludedPaths, __y => TypeConverterExtensions.SelectToArray<string>(__y, global::System.Convert.ToString));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentMacExcludedPaths = (string[]) content.GetValueForProperty("BackupContentMacExcludedPaths",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentMacExcludedPaths, __y => TypeConverterExtensions.SelectToArray<string>(__y, global::System.Convert.ToString));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentUnixIncludedPaths = (string[]) content.GetValueForProperty("BackupContentUnixIncludedPaths",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentUnixIncludedPaths, __y => TypeConverterExtensions.SelectToArray<string>(__y, global::System.Convert.ToString));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentUnixExcludedPaths = (string[]) content.GetValueForProperty("BackupContentUnixExcludedPaths",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupContentUnixExcludedPaths, __y => TypeConverterExtensions.SelectToArray<string>(__y, global::System.Convert.ToString));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).SnapshotOptionSnapRecoveryPoints = (long?) content.GetValueForProperty("SnapshotOptionSnapRecoveryPoints",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).SnapshotOptionSnapRecoveryPoints, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).SnapshotOptionRetentionPeriodDays = (long?) content.GetValueForProperty("SnapshotOptionRetentionPeriodDays",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).SnapshotOptionRetentionPeriodDays, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).SnapshotOptionEnableBackupCopy = (bool?) content.GetValueForProperty("SnapshotOptionEnableBackupCopy",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).SnapshotOptionEnableBackupCopy, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).SnapshotOptionBackupCopyRpoMins = (long?) content.GetValueForProperty("SnapshotOptionBackupCopyRpoMins",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).SnapshotOptionBackupCopyRpoMins, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).DatabaseOptionLogBackupRpoMins = (long?) content.GetValueForProperty("DatabaseOptionLogBackupRpoMins",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).DatabaseOptionLogBackupRpoMins, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).DatabaseOptionUseDiskCacheForLogBackups = (bool?) content.GetValueForProperty("DatabaseOptionUseDiskCacheForLogBackups",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).DatabaseOptionUseDiskCacheForLogBackups, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).DatabaseOptionCommitFrequencyInHours = (long?) content.GetValueForProperty("DatabaseOptionCommitFrequencyInHours",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).DatabaseOptionCommitFrequencyInHours, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).OverrideRestrictionBackupContent = (string) content.GetValueForProperty("OverrideRestrictionBackupContent",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).OverrideRestrictionBackupContent, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).OverrideRestrictionStoragePool = (string) content.GetValueForProperty("OverrideRestrictionStoragePool",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).OverrideRestrictionStoragePool, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).OverrideRestrictionRpo = (string) content.GetValueForProperty("OverrideRestrictionRpo",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).OverrideRestrictionRpo, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).ParentPlanId = (long?) content.GetValueForProperty("ParentPlanId",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).ParentPlanId, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).ParentPlanName = (string) content.GetValueForProperty("ParentPlanName",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).ParentPlanName, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupFrequencySchedules = (Commvault.Powershell.Models.IPlanSchedule[]) content.GetValueForProperty("BackupFrequencySchedules",((Commvault.Powershell.Models.ICreateServerPlanInternal)this).BackupFrequencySchedules, __y => TypeConverterExtensions.SelectToArray<Commvault.Powershell.Models.IPlanSchedule>(__y, Commvault.Powershell.Models.PlanScheduleTypeConverter.ConvertFrom));
            AfterDeserializePSObject(content);
        }

        /// <summary>
        /// Deserializes a <see cref="global::System.Collections.IDictionary" /> into an instance of <see cref="Commvault.Powershell.Models.CreateServerPlan"
        /// />.
        /// </summary>
        /// <param name="content">The global::System.Collections.IDictionary content that should be used.</param>
        /// <returns>an instance of <see cref="Commvault.Powershell.Models.ICreateServerPlan" />.</returns>
        public static Commvault.Powershell.Models.ICreateServerPlan DeserializeFromDictionary(global::System.Collections.IDictionary content)
        {
            return new CreateServerPlan(content);
        }

        /// <summary>
        /// Deserializes a <see cref="global::System.Management.Automation.PSObject" /> into an instance of <see cref="Commvault.Powershell.Models.CreateServerPlan"
        /// />.
        /// </summary>
        /// <param name="content">The global::System.Management.Automation.PSObject content that should be used.</param>
        /// <returns>an instance of <see cref="Commvault.Powershell.Models.ICreateServerPlan" />.</returns>
        public static Commvault.Powershell.Models.ICreateServerPlan DeserializeFromPSObject(global::System.Management.Automation.PSObject content)
        {
            return new CreateServerPlan(content);
        }

        /// <summary>
        /// Creates a new instance of <see cref="CreateServerPlan" />, deserializing the content from a json string.
        /// </summary>
        /// <param name="jsonText">a string containing a JSON serialized instance of this model.</param>
        /// <returns>an instance of the <see cref="className" /> model class.</returns>
        public static Commvault.Powershell.Models.ICreateServerPlan FromJsonString(string jsonText) => FromJson(Commvault.Powershell.Runtime.Json.JsonNode.Parse(jsonText));

        /// <summary>Serializes this instance to a json string.</summary>

        /// <returns>a <see cref="System.String" /> containing this model serialized to JSON text.</returns>
        public string ToJsonString() => ToJson(null, Commvault.Powershell.Runtime.SerializationMode.IncludeAll)?.ToString();
    }
    [System.ComponentModel.TypeConverter(typeof(CreateServerPlanTypeConverter))]
    public partial interface ICreateServerPlan

    {

    }
}