generated/api/Models/ServerPlan.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(ServerPlanTypeConverter))]
    public partial class ServerPlan
    {

        /// <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 an instance of <see cref="Commvault.Powershell.Models.ServerPlan"
        /// />.
        /// </summary>
        /// <param name="content">The global::System.Collections.IDictionary content that should be used.</param>
        /// <returns>an instance of <see cref="Commvault.Powershell.Models.IServerPlan" />.</returns>
        public static Commvault.Powershell.Models.IServerPlan DeserializeFromDictionary(global::System.Collections.IDictionary content)
        {
            return new ServerPlan(content);
        }

        /// <summary>
        /// Deserializes a <see cref="global::System.Management.Automation.PSObject" /> into an instance of <see cref="Commvault.Powershell.Models.ServerPlan"
        /// />.
        /// </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.IServerPlan" />.</returns>
        public static Commvault.Powershell.Models.IServerPlan DeserializeFromPSObject(global::System.Management.Automation.PSObject content)
        {
            return new ServerPlan(content);
        }

        /// <summary>
        /// Creates a new instance of <see cref="ServerPlan" />, 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.IServerPlan FromJsonString(string jsonText) => FromJson(Commvault.Powershell.Runtime.Json.JsonNode.Parse(jsonText));

        /// <summary>
        /// Deserializes a <see cref="global::System.Collections.IDictionary" /> into a new instance of <see cref="Commvault.Powershell.Models.ServerPlan"
        /// />.
        /// </summary>
        /// <param name="content">The global::System.Collections.IDictionary content that should be used.</param>
        internal ServerPlan(global::System.Collections.IDictionary content)
        {
            bool returnNow = false;
            BeforeDeserializeDictionary(content, ref returnNow);
            if (returnNow)
            {
                return;
            }
            // actually deserialize
            ((Commvault.Powershell.Models.IServerPlanInternal)this).Plan = (Commvault.Powershell.Models.IIdName) content.GetValueForProperty("Plan",((Commvault.Powershell.Models.IServerPlanInternal)this).Plan, Commvault.Powershell.Models.IdNameTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContent = (Commvault.Powershell.Models.IPlanContent) content.GetValueForProperty("BackupContent",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContent, Commvault.Powershell.Models.PlanContentTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).Rpo = (Commvault.Powershell.Models.IServerPlanRpo) content.GetValueForProperty("Rpo",((Commvault.Powershell.Models.IServerPlanInternal)this).Rpo, Commvault.Powershell.Models.ServerPlanRpoTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).DatabaseOptions = (Commvault.Powershell.Models.IServerPlanDatabaseOptionsInfo) content.GetValueForProperty("DatabaseOptions",((Commvault.Powershell.Models.IServerPlanInternal)this).DatabaseOptions, Commvault.Powershell.Models.ServerPlanDatabaseOptionsInfoTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).SnapshotOptions = (Commvault.Powershell.Models.IPlanSnapshotOptions) content.GetValueForProperty("SnapshotOptions",((Commvault.Powershell.Models.IServerPlanInternal)this).SnapshotOptions, Commvault.Powershell.Models.PlanSnapshotOptionsTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).Settings = (Commvault.Powershell.Models.IServerPlanSettings) content.GetValueForProperty("Settings",((Commvault.Powershell.Models.IServerPlanInternal)this).Settings, Commvault.Powershell.Models.ServerPlanSettingsTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).OverrideRestrictions = (Commvault.Powershell.Models.IPlanOverrideSettings) content.GetValueForProperty("OverrideRestrictions",((Commvault.Powershell.Models.IServerPlanInternal)this).OverrideRestrictions, Commvault.Powershell.Models.PlanOverrideSettingsTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).InheritSettings = (Commvault.Powershell.Models.IServerPlanInheritSettings) content.GetValueForProperty("InheritSettings",((Commvault.Powershell.Models.IServerPlanInternal)this).InheritSettings, Commvault.Powershell.Models.ServerPlanInheritSettingsTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).AdditionalProperties = (Commvault.Powershell.Models.IPlanAdditionalProperties) content.GetValueForProperty("AdditionalProperties",((Commvault.Powershell.Models.IServerPlanInternal)this).AdditionalProperties, Commvault.Powershell.Models.PlanAdditionalPropertiesTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).RegionsConfigured = (bool?) content.GetValueForProperty("RegionsConfigured",((Commvault.Powershell.Models.IServerPlanInternal)this).RegionsConfigured, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupDestinations = (Commvault.Powershell.Models.IPlanBackupDestination[]) content.GetValueForProperty("BackupDestinations",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupDestinations, __y => TypeConverterExtensions.SelectToArray<Commvault.Powershell.Models.IPlanBackupDestination>(__y, Commvault.Powershell.Models.PlanBackupDestinationTypeConverter.ConvertFrom));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).AssociatedEntities = (Commvault.Powershell.Models.IIdNameCount[]) content.GetValueForProperty("AssociatedEntities",((Commvault.Powershell.Models.IServerPlanInternal)this).AssociatedEntities, __y => TypeConverterExtensions.SelectToArray<Commvault.Powershell.Models.IIdNameCount>(__y, Commvault.Powershell.Models.IdNameCountTypeConverter.ConvertFrom));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).AllowPlanOverride = (bool?) content.GetValueForProperty("AllowPlanOverride",((Commvault.Powershell.Models.IServerPlanInternal)this).AllowPlanOverride, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).Permissions = (Commvault.Powershell.Models.IIdName[]) content.GetValueForProperty("Permissions",((Commvault.Powershell.Models.IServerPlanInternal)this).Permissions, __y => TypeConverterExtensions.SelectToArray<Commvault.Powershell.Models.IIdName>(__y, Commvault.Powershell.Models.IdNameTypeConverter.ConvertFrom));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).PlanId = (long?) content.GetValueForProperty("PlanId",((Commvault.Powershell.Models.IServerPlanInternal)this).PlanId, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).PlanName = (string) content.GetValueForProperty("PlanName",((Commvault.Powershell.Models.IServerPlanInternal)this).PlanName, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentWindowsIncludedPaths = (string[]) content.GetValueForProperty("BackupContentWindowsIncludedPaths",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentWindowsIncludedPaths, __y => TypeConverterExtensions.SelectToArray<string>(__y, global::System.Convert.ToString));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentWindowsExcludedPaths = (string[]) content.GetValueForProperty("BackupContentWindowsExcludedPaths",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentWindowsExcludedPaths, __y => TypeConverterExtensions.SelectToArray<string>(__y, global::System.Convert.ToString));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentBackupSystemState = (bool?) content.GetValueForProperty("BackupContentBackupSystemState",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentBackupSystemState, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentBackupSystemStateOnlyWithFullBackup = (bool?) content.GetValueForProperty("BackupContentBackupSystemStateOnlyWithFullBackup",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentBackupSystemStateOnlyWithFullBackup, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentUseVssForSystemState = (bool?) content.GetValueForProperty("BackupContentUseVssForSystemState",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentUseVssForSystemState, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentMacIncludedPaths = (string[]) content.GetValueForProperty("BackupContentMacIncludedPaths",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentMacIncludedPaths, __y => TypeConverterExtensions.SelectToArray<string>(__y, global::System.Convert.ToString));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentMacExcludedPaths = (string[]) content.GetValueForProperty("BackupContentMacExcludedPaths",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentMacExcludedPaths, __y => TypeConverterExtensions.SelectToArray<string>(__y, global::System.Convert.ToString));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentUnixIncludedPaths = (string[]) content.GetValueForProperty("BackupContentUnixIncludedPaths",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentUnixIncludedPaths, __y => TypeConverterExtensions.SelectToArray<string>(__y, global::System.Convert.ToString));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentUnixExcludedPaths = (string[]) content.GetValueForProperty("BackupContentUnixExcludedPaths",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentUnixExcludedPaths, __y => TypeConverterExtensions.SelectToArray<string>(__y, global::System.Convert.ToString));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).RpoBackupFrequency = (Commvault.Powershell.Models.IPlanSchedules) content.GetValueForProperty("RpoBackupFrequency",((Commvault.Powershell.Models.IServerPlanInternal)this).RpoBackupFrequency, Commvault.Powershell.Models.PlanSchedulesTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).RpoSla = (Commvault.Powershell.Models.ISlaOptions) content.GetValueForProperty("RpoSla",((Commvault.Powershell.Models.IServerPlanInternal)this).RpoSla, Commvault.Powershell.Models.SlaOptionsTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).RpoBackupWindow = (Commvault.Powershell.Models.IDayAndTime[]) content.GetValueForProperty("RpoBackupWindow",((Commvault.Powershell.Models.IServerPlanInternal)this).RpoBackupWindow, __y => TypeConverterExtensions.SelectToArray<Commvault.Powershell.Models.IDayAndTime>(__y, Commvault.Powershell.Models.DayAndTimeTypeConverter.ConvertFrom));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).RpoFullBackupWindow = (Commvault.Powershell.Models.IDayAndTime[]) content.GetValueForProperty("RpoFullBackupWindow",((Commvault.Powershell.Models.IServerPlanInternal)this).RpoFullBackupWindow, __y => TypeConverterExtensions.SelectToArray<Commvault.Powershell.Models.IDayAndTime>(__y, Commvault.Powershell.Models.DayAndTimeTypeConverter.ConvertFrom));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).DatabaseOptionLogBackupRpoMins = (long?) content.GetValueForProperty("DatabaseOptionLogBackupRpoMins",((Commvault.Powershell.Models.IServerPlanInternal)this).DatabaseOptionLogBackupRpoMins, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).DatabaseOptionRunFullBackupEvery = (long?) content.GetValueForProperty("DatabaseOptionRunFullBackupEvery",((Commvault.Powershell.Models.IServerPlanInternal)this).DatabaseOptionRunFullBackupEvery, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).DatabaseOptionUseDiskCacheForLogBackups = (bool?) content.GetValueForProperty("DatabaseOptionUseDiskCacheForLogBackups",((Commvault.Powershell.Models.IServerPlanInternal)this).DatabaseOptionUseDiskCacheForLogBackups, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).DatabaseOptionCommitFrequencyInHours = (long?) content.GetValueForProperty("DatabaseOptionCommitFrequencyInHours",((Commvault.Powershell.Models.IServerPlanInternal)this).DatabaseOptionCommitFrequencyInHours, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).SnapshotOptionEnableBackupCopy = (bool?) content.GetValueForProperty("SnapshotOptionEnableBackupCopy",((Commvault.Powershell.Models.IServerPlanInternal)this).SnapshotOptionEnableBackupCopy, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).SnapshotOptionBackupCopyRpoMins = (long?) content.GetValueForProperty("SnapshotOptionBackupCopyRpoMins",((Commvault.Powershell.Models.IServerPlanInternal)this).SnapshotOptionBackupCopyRpoMins, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).SettingFileSearch = (Commvault.Powershell.Models.IPlanFileSearch) content.GetValueForProperty("SettingFileSearch",((Commvault.Powershell.Models.IServerPlanInternal)this).SettingFileSearch, Commvault.Powershell.Models.PlanFileSearchTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).OverrideRestrictionBackupContent = (string) content.GetValueForProperty("OverrideRestrictionBackupContent",((Commvault.Powershell.Models.IServerPlanInternal)this).OverrideRestrictionBackupContent, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).OverrideRestrictionStoragePool = (string) content.GetValueForProperty("OverrideRestrictionStoragePool",((Commvault.Powershell.Models.IServerPlanInternal)this).OverrideRestrictionStoragePool, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).OverrideRestrictionRpo = (string) content.GetValueForProperty("OverrideRestrictionRpo",((Commvault.Powershell.Models.IServerPlanInternal)this).OverrideRestrictionRpo, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).InheritSettingBasePlan = (Commvault.Powershell.Models.IIdName) content.GetValueForProperty("InheritSettingBasePlan",((Commvault.Powershell.Models.IServerPlanInternal)this).InheritSettingBasePlan, Commvault.Powershell.Models.IdNameTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).InheritSettingStoragePool = (Commvault.Powershell.Models.IPlanOverridenOptions) content.GetValueForProperty("InheritSettingStoragePool",((Commvault.Powershell.Models.IServerPlanInternal)this).InheritSettingStoragePool, Commvault.Powershell.Models.PlanOverridenOptionsTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).InheritSettingRpo = (Commvault.Powershell.Models.IPlanOverridenOptions) content.GetValueForProperty("InheritSettingRpo",((Commvault.Powershell.Models.IServerPlanInternal)this).InheritSettingRpo, Commvault.Powershell.Models.PlanOverridenOptionsTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).InheritSettingBackupContent = (Commvault.Powershell.Models.IPlanOverridenOptions) content.GetValueForProperty("InheritSettingBackupContent",((Commvault.Powershell.Models.IServerPlanInternal)this).InheritSettingBackupContent, Commvault.Powershell.Models.PlanOverridenOptionsTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).AdditionalPropertyAddons = (Commvault.Powershell.Models.IPlanAddons) content.GetValueForProperty("AdditionalPropertyAddons",((Commvault.Powershell.Models.IServerPlanInternal)this).AdditionalPropertyAddons, Commvault.Powershell.Models.PlanAddonsTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupFrequencySchedules = (Commvault.Powershell.Models.IPlanSchedule[]) content.GetValueForProperty("BackupFrequencySchedules",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupFrequencySchedules, __y => TypeConverterExtensions.SelectToArray<Commvault.Powershell.Models.IPlanSchedule>(__y, Commvault.Powershell.Models.PlanScheduleTypeConverter.ConvertFrom));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).SlaUseSystemDefaultSla = (bool?) content.GetValueForProperty("SlaUseSystemDefaultSla",((Commvault.Powershell.Models.IServerPlanInternal)this).SlaUseSystemDefaultSla, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).SlaInheritedSlaPeriod = (long?) content.GetValueForProperty("SlaInheritedSlaPeriod",((Commvault.Powershell.Models.IServerPlanInternal)this).SlaInheritedSlaPeriod, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).SlaInheritedFrom = (string) content.GetValueForProperty("SlaInheritedFrom",((Commvault.Powershell.Models.IServerPlanInternal)this).SlaInheritedFrom, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).SlaPeriod = (long?) content.GetValueForProperty("SlaPeriod",((Commvault.Powershell.Models.IServerPlanInternal)this).SlaPeriod, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).SlaExcludeFromSla = (bool?) content.GetValueForProperty("SlaExcludeFromSla",((Commvault.Powershell.Models.IServerPlanInternal)this).SlaExcludeFromSla, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).SlaEnableAfterDelay = (long?) content.GetValueForProperty("SlaEnableAfterDelay",((Commvault.Powershell.Models.IServerPlanInternal)this).SlaEnableAfterDelay, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).SlaExclusionReason = (string) content.GetValueForProperty("SlaExclusionReason",((Commvault.Powershell.Models.IServerPlanInternal)this).SlaExclusionReason, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).FileSearchEnabled = (bool?) content.GetValueForProperty("FileSearchEnabled",((Commvault.Powershell.Models.IServerPlanInternal)this).FileSearchEnabled, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).FileSearchStatus = (string) content.GetValueForProperty("FileSearchStatus",((Commvault.Powershell.Models.IServerPlanInternal)this).FileSearchStatus, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).FileSearchStatusMessage = (string) content.GetValueForProperty("FileSearchStatusMessage",((Commvault.Powershell.Models.IServerPlanInternal)this).FileSearchStatusMessage, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BasePlanId = (long?) content.GetValueForProperty("BasePlanId",((Commvault.Powershell.Models.IServerPlanInternal)this).BasePlanId, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BasePlanName = (string) content.GetValueForProperty("BasePlanName",((Commvault.Powershell.Models.IServerPlanInternal)this).BasePlanName, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).StoragePoolOverrideBase = (string) content.GetValueForProperty("StoragePoolOverrideBase",((Commvault.Powershell.Models.IServerPlanInternal)this).StoragePoolOverrideBase, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).StoragePoolOverridden = (bool?) content.GetValueForProperty("StoragePoolOverridden",((Commvault.Powershell.Models.IServerPlanInternal)this).StoragePoolOverridden, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).RpoOverrideBase = (string) content.GetValueForProperty("RpoOverrideBase",((Commvault.Powershell.Models.IServerPlanInternal)this).RpoOverrideBase, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).RpoOverridden = (bool?) content.GetValueForProperty("RpoOverridden",((Commvault.Powershell.Models.IServerPlanInternal)this).RpoOverridden, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentOverrideBase = (string) content.GetValueForProperty("BackupContentOverrideBase",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentOverrideBase, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentOverridden = (bool?) content.GetValueForProperty("BackupContentOverridden",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentOverridden, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).AddonDatabase = (bool?) content.GetValueForProperty("AddonDatabase",((Commvault.Powershell.Models.IServerPlanInternal)this).AddonDatabase, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).AddonFileSystem = (bool?) content.GetValueForProperty("AddonFileSystem",((Commvault.Powershell.Models.IServerPlanInternal)this).AddonFileSystem, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).AddonSnap = (bool?) content.GetValueForProperty("AddonSnap",((Commvault.Powershell.Models.IServerPlanInternal)this).AddonSnap, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).AddonSnapStatus = (string) content.GetValueForProperty("AddonSnapStatus",((Commvault.Powershell.Models.IServerPlanInternal)this).AddonSnapStatus, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).AddonIndexCopy = (bool?) content.GetValueForProperty("AddonIndexCopy",((Commvault.Powershell.Models.IServerPlanInternal)this).AddonIndexCopy, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            AfterDeserializeDictionary(content);
        }

        /// <summary>
        /// Deserializes a <see cref="global::System.Management.Automation.PSObject" /> into a new instance of <see cref="Commvault.Powershell.Models.ServerPlan"
        /// />.
        /// </summary>
        /// <param name="content">The global::System.Management.Automation.PSObject content that should be used.</param>
        internal ServerPlan(global::System.Management.Automation.PSObject content)
        {
            bool returnNow = false;
            BeforeDeserializePSObject(content, ref returnNow);
            if (returnNow)
            {
                return;
            }
            // actually deserialize
            ((Commvault.Powershell.Models.IServerPlanInternal)this).Plan = (Commvault.Powershell.Models.IIdName) content.GetValueForProperty("Plan",((Commvault.Powershell.Models.IServerPlanInternal)this).Plan, Commvault.Powershell.Models.IdNameTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContent = (Commvault.Powershell.Models.IPlanContent) content.GetValueForProperty("BackupContent",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContent, Commvault.Powershell.Models.PlanContentTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).Rpo = (Commvault.Powershell.Models.IServerPlanRpo) content.GetValueForProperty("Rpo",((Commvault.Powershell.Models.IServerPlanInternal)this).Rpo, Commvault.Powershell.Models.ServerPlanRpoTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).DatabaseOptions = (Commvault.Powershell.Models.IServerPlanDatabaseOptionsInfo) content.GetValueForProperty("DatabaseOptions",((Commvault.Powershell.Models.IServerPlanInternal)this).DatabaseOptions, Commvault.Powershell.Models.ServerPlanDatabaseOptionsInfoTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).SnapshotOptions = (Commvault.Powershell.Models.IPlanSnapshotOptions) content.GetValueForProperty("SnapshotOptions",((Commvault.Powershell.Models.IServerPlanInternal)this).SnapshotOptions, Commvault.Powershell.Models.PlanSnapshotOptionsTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).Settings = (Commvault.Powershell.Models.IServerPlanSettings) content.GetValueForProperty("Settings",((Commvault.Powershell.Models.IServerPlanInternal)this).Settings, Commvault.Powershell.Models.ServerPlanSettingsTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).OverrideRestrictions = (Commvault.Powershell.Models.IPlanOverrideSettings) content.GetValueForProperty("OverrideRestrictions",((Commvault.Powershell.Models.IServerPlanInternal)this).OverrideRestrictions, Commvault.Powershell.Models.PlanOverrideSettingsTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).InheritSettings = (Commvault.Powershell.Models.IServerPlanInheritSettings) content.GetValueForProperty("InheritSettings",((Commvault.Powershell.Models.IServerPlanInternal)this).InheritSettings, Commvault.Powershell.Models.ServerPlanInheritSettingsTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).AdditionalProperties = (Commvault.Powershell.Models.IPlanAdditionalProperties) content.GetValueForProperty("AdditionalProperties",((Commvault.Powershell.Models.IServerPlanInternal)this).AdditionalProperties, Commvault.Powershell.Models.PlanAdditionalPropertiesTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).RegionsConfigured = (bool?) content.GetValueForProperty("RegionsConfigured",((Commvault.Powershell.Models.IServerPlanInternal)this).RegionsConfigured, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupDestinations = (Commvault.Powershell.Models.IPlanBackupDestination[]) content.GetValueForProperty("BackupDestinations",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupDestinations, __y => TypeConverterExtensions.SelectToArray<Commvault.Powershell.Models.IPlanBackupDestination>(__y, Commvault.Powershell.Models.PlanBackupDestinationTypeConverter.ConvertFrom));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).AssociatedEntities = (Commvault.Powershell.Models.IIdNameCount[]) content.GetValueForProperty("AssociatedEntities",((Commvault.Powershell.Models.IServerPlanInternal)this).AssociatedEntities, __y => TypeConverterExtensions.SelectToArray<Commvault.Powershell.Models.IIdNameCount>(__y, Commvault.Powershell.Models.IdNameCountTypeConverter.ConvertFrom));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).AllowPlanOverride = (bool?) content.GetValueForProperty("AllowPlanOverride",((Commvault.Powershell.Models.IServerPlanInternal)this).AllowPlanOverride, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).Permissions = (Commvault.Powershell.Models.IIdName[]) content.GetValueForProperty("Permissions",((Commvault.Powershell.Models.IServerPlanInternal)this).Permissions, __y => TypeConverterExtensions.SelectToArray<Commvault.Powershell.Models.IIdName>(__y, Commvault.Powershell.Models.IdNameTypeConverter.ConvertFrom));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).PlanId = (long?) content.GetValueForProperty("PlanId",((Commvault.Powershell.Models.IServerPlanInternal)this).PlanId, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).PlanName = (string) content.GetValueForProperty("PlanName",((Commvault.Powershell.Models.IServerPlanInternal)this).PlanName, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentWindowsIncludedPaths = (string[]) content.GetValueForProperty("BackupContentWindowsIncludedPaths",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentWindowsIncludedPaths, __y => TypeConverterExtensions.SelectToArray<string>(__y, global::System.Convert.ToString));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentWindowsExcludedPaths = (string[]) content.GetValueForProperty("BackupContentWindowsExcludedPaths",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentWindowsExcludedPaths, __y => TypeConverterExtensions.SelectToArray<string>(__y, global::System.Convert.ToString));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentBackupSystemState = (bool?) content.GetValueForProperty("BackupContentBackupSystemState",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentBackupSystemState, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentBackupSystemStateOnlyWithFullBackup = (bool?) content.GetValueForProperty("BackupContentBackupSystemStateOnlyWithFullBackup",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentBackupSystemStateOnlyWithFullBackup, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentUseVssForSystemState = (bool?) content.GetValueForProperty("BackupContentUseVssForSystemState",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentUseVssForSystemState, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentMacIncludedPaths = (string[]) content.GetValueForProperty("BackupContentMacIncludedPaths",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentMacIncludedPaths, __y => TypeConverterExtensions.SelectToArray<string>(__y, global::System.Convert.ToString));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentMacExcludedPaths = (string[]) content.GetValueForProperty("BackupContentMacExcludedPaths",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentMacExcludedPaths, __y => TypeConverterExtensions.SelectToArray<string>(__y, global::System.Convert.ToString));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentUnixIncludedPaths = (string[]) content.GetValueForProperty("BackupContentUnixIncludedPaths",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentUnixIncludedPaths, __y => TypeConverterExtensions.SelectToArray<string>(__y, global::System.Convert.ToString));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentUnixExcludedPaths = (string[]) content.GetValueForProperty("BackupContentUnixExcludedPaths",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentUnixExcludedPaths, __y => TypeConverterExtensions.SelectToArray<string>(__y, global::System.Convert.ToString));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).RpoBackupFrequency = (Commvault.Powershell.Models.IPlanSchedules) content.GetValueForProperty("RpoBackupFrequency",((Commvault.Powershell.Models.IServerPlanInternal)this).RpoBackupFrequency, Commvault.Powershell.Models.PlanSchedulesTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).RpoSla = (Commvault.Powershell.Models.ISlaOptions) content.GetValueForProperty("RpoSla",((Commvault.Powershell.Models.IServerPlanInternal)this).RpoSla, Commvault.Powershell.Models.SlaOptionsTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).RpoBackupWindow = (Commvault.Powershell.Models.IDayAndTime[]) content.GetValueForProperty("RpoBackupWindow",((Commvault.Powershell.Models.IServerPlanInternal)this).RpoBackupWindow, __y => TypeConverterExtensions.SelectToArray<Commvault.Powershell.Models.IDayAndTime>(__y, Commvault.Powershell.Models.DayAndTimeTypeConverter.ConvertFrom));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).RpoFullBackupWindow = (Commvault.Powershell.Models.IDayAndTime[]) content.GetValueForProperty("RpoFullBackupWindow",((Commvault.Powershell.Models.IServerPlanInternal)this).RpoFullBackupWindow, __y => TypeConverterExtensions.SelectToArray<Commvault.Powershell.Models.IDayAndTime>(__y, Commvault.Powershell.Models.DayAndTimeTypeConverter.ConvertFrom));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).DatabaseOptionLogBackupRpoMins = (long?) content.GetValueForProperty("DatabaseOptionLogBackupRpoMins",((Commvault.Powershell.Models.IServerPlanInternal)this).DatabaseOptionLogBackupRpoMins, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).DatabaseOptionRunFullBackupEvery = (long?) content.GetValueForProperty("DatabaseOptionRunFullBackupEvery",((Commvault.Powershell.Models.IServerPlanInternal)this).DatabaseOptionRunFullBackupEvery, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).DatabaseOptionUseDiskCacheForLogBackups = (bool?) content.GetValueForProperty("DatabaseOptionUseDiskCacheForLogBackups",((Commvault.Powershell.Models.IServerPlanInternal)this).DatabaseOptionUseDiskCacheForLogBackups, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).DatabaseOptionCommitFrequencyInHours = (long?) content.GetValueForProperty("DatabaseOptionCommitFrequencyInHours",((Commvault.Powershell.Models.IServerPlanInternal)this).DatabaseOptionCommitFrequencyInHours, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).SnapshotOptionEnableBackupCopy = (bool?) content.GetValueForProperty("SnapshotOptionEnableBackupCopy",((Commvault.Powershell.Models.IServerPlanInternal)this).SnapshotOptionEnableBackupCopy, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).SnapshotOptionBackupCopyRpoMins = (long?) content.GetValueForProperty("SnapshotOptionBackupCopyRpoMins",((Commvault.Powershell.Models.IServerPlanInternal)this).SnapshotOptionBackupCopyRpoMins, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).SettingFileSearch = (Commvault.Powershell.Models.IPlanFileSearch) content.GetValueForProperty("SettingFileSearch",((Commvault.Powershell.Models.IServerPlanInternal)this).SettingFileSearch, Commvault.Powershell.Models.PlanFileSearchTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).OverrideRestrictionBackupContent = (string) content.GetValueForProperty("OverrideRestrictionBackupContent",((Commvault.Powershell.Models.IServerPlanInternal)this).OverrideRestrictionBackupContent, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).OverrideRestrictionStoragePool = (string) content.GetValueForProperty("OverrideRestrictionStoragePool",((Commvault.Powershell.Models.IServerPlanInternal)this).OverrideRestrictionStoragePool, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).OverrideRestrictionRpo = (string) content.GetValueForProperty("OverrideRestrictionRpo",((Commvault.Powershell.Models.IServerPlanInternal)this).OverrideRestrictionRpo, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).InheritSettingBasePlan = (Commvault.Powershell.Models.IIdName) content.GetValueForProperty("InheritSettingBasePlan",((Commvault.Powershell.Models.IServerPlanInternal)this).InheritSettingBasePlan, Commvault.Powershell.Models.IdNameTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).InheritSettingStoragePool = (Commvault.Powershell.Models.IPlanOverridenOptions) content.GetValueForProperty("InheritSettingStoragePool",((Commvault.Powershell.Models.IServerPlanInternal)this).InheritSettingStoragePool, Commvault.Powershell.Models.PlanOverridenOptionsTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).InheritSettingRpo = (Commvault.Powershell.Models.IPlanOverridenOptions) content.GetValueForProperty("InheritSettingRpo",((Commvault.Powershell.Models.IServerPlanInternal)this).InheritSettingRpo, Commvault.Powershell.Models.PlanOverridenOptionsTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).InheritSettingBackupContent = (Commvault.Powershell.Models.IPlanOverridenOptions) content.GetValueForProperty("InheritSettingBackupContent",((Commvault.Powershell.Models.IServerPlanInternal)this).InheritSettingBackupContent, Commvault.Powershell.Models.PlanOverridenOptionsTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).AdditionalPropertyAddons = (Commvault.Powershell.Models.IPlanAddons) content.GetValueForProperty("AdditionalPropertyAddons",((Commvault.Powershell.Models.IServerPlanInternal)this).AdditionalPropertyAddons, Commvault.Powershell.Models.PlanAddonsTypeConverter.ConvertFrom);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupFrequencySchedules = (Commvault.Powershell.Models.IPlanSchedule[]) content.GetValueForProperty("BackupFrequencySchedules",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupFrequencySchedules, __y => TypeConverterExtensions.SelectToArray<Commvault.Powershell.Models.IPlanSchedule>(__y, Commvault.Powershell.Models.PlanScheduleTypeConverter.ConvertFrom));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).SlaUseSystemDefaultSla = (bool?) content.GetValueForProperty("SlaUseSystemDefaultSla",((Commvault.Powershell.Models.IServerPlanInternal)this).SlaUseSystemDefaultSla, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).SlaInheritedSlaPeriod = (long?) content.GetValueForProperty("SlaInheritedSlaPeriod",((Commvault.Powershell.Models.IServerPlanInternal)this).SlaInheritedSlaPeriod, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).SlaInheritedFrom = (string) content.GetValueForProperty("SlaInheritedFrom",((Commvault.Powershell.Models.IServerPlanInternal)this).SlaInheritedFrom, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).SlaPeriod = (long?) content.GetValueForProperty("SlaPeriod",((Commvault.Powershell.Models.IServerPlanInternal)this).SlaPeriod, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).SlaExcludeFromSla = (bool?) content.GetValueForProperty("SlaExcludeFromSla",((Commvault.Powershell.Models.IServerPlanInternal)this).SlaExcludeFromSla, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).SlaEnableAfterDelay = (long?) content.GetValueForProperty("SlaEnableAfterDelay",((Commvault.Powershell.Models.IServerPlanInternal)this).SlaEnableAfterDelay, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).SlaExclusionReason = (string) content.GetValueForProperty("SlaExclusionReason",((Commvault.Powershell.Models.IServerPlanInternal)this).SlaExclusionReason, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).FileSearchEnabled = (bool?) content.GetValueForProperty("FileSearchEnabled",((Commvault.Powershell.Models.IServerPlanInternal)this).FileSearchEnabled, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).FileSearchStatus = (string) content.GetValueForProperty("FileSearchStatus",((Commvault.Powershell.Models.IServerPlanInternal)this).FileSearchStatus, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).FileSearchStatusMessage = (string) content.GetValueForProperty("FileSearchStatusMessage",((Commvault.Powershell.Models.IServerPlanInternal)this).FileSearchStatusMessage, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BasePlanId = (long?) content.GetValueForProperty("BasePlanId",((Commvault.Powershell.Models.IServerPlanInternal)this).BasePlanId, (__y)=> (long) global::System.Convert.ChangeType(__y, typeof(long)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BasePlanName = (string) content.GetValueForProperty("BasePlanName",((Commvault.Powershell.Models.IServerPlanInternal)this).BasePlanName, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).StoragePoolOverrideBase = (string) content.GetValueForProperty("StoragePoolOverrideBase",((Commvault.Powershell.Models.IServerPlanInternal)this).StoragePoolOverrideBase, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).StoragePoolOverridden = (bool?) content.GetValueForProperty("StoragePoolOverridden",((Commvault.Powershell.Models.IServerPlanInternal)this).StoragePoolOverridden, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).RpoOverrideBase = (string) content.GetValueForProperty("RpoOverrideBase",((Commvault.Powershell.Models.IServerPlanInternal)this).RpoOverrideBase, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).RpoOverridden = (bool?) content.GetValueForProperty("RpoOverridden",((Commvault.Powershell.Models.IServerPlanInternal)this).RpoOverridden, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentOverrideBase = (string) content.GetValueForProperty("BackupContentOverrideBase",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentOverrideBase, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentOverridden = (bool?) content.GetValueForProperty("BackupContentOverridden",((Commvault.Powershell.Models.IServerPlanInternal)this).BackupContentOverridden, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).AddonDatabase = (bool?) content.GetValueForProperty("AddonDatabase",((Commvault.Powershell.Models.IServerPlanInternal)this).AddonDatabase, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).AddonFileSystem = (bool?) content.GetValueForProperty("AddonFileSystem",((Commvault.Powershell.Models.IServerPlanInternal)this).AddonFileSystem, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).AddonSnap = (bool?) content.GetValueForProperty("AddonSnap",((Commvault.Powershell.Models.IServerPlanInternal)this).AddonSnap, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            ((Commvault.Powershell.Models.IServerPlanInternal)this).AddonSnapStatus = (string) content.GetValueForProperty("AddonSnapStatus",((Commvault.Powershell.Models.IServerPlanInternal)this).AddonSnapStatus, global::System.Convert.ToString);
            ((Commvault.Powershell.Models.IServerPlanInternal)this).AddonIndexCopy = (bool?) content.GetValueForProperty("AddonIndexCopy",((Commvault.Powershell.Models.IServerPlanInternal)this).AddonIndexCopy, (__y)=> (bool) global::System.Convert.ChangeType(__y, typeof(bool)));
            AfterDeserializePSObject(content);
        }

        /// <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(ServerPlanTypeConverter))]
    public partial interface IServerPlan

    {

    }
}