public override string ToString() { StringBuilder stringBuilder = new StringBuilder(); LegacyThrottlingPolicy.AppendSettingsString(stringBuilder, "Anonymous", this.AnonymousThrottlingPolicyStateSettings); LegacyThrottlingPolicy.AppendSettingsString(stringBuilder, "Eas", this.EasThrottlingPolicyStateSettings); LegacyThrottlingPolicy.AppendSettingsString(stringBuilder, "Ews", this.EwsThrottlingPolicyStateSettings); LegacyThrottlingPolicy.AppendSettingsString(stringBuilder, "Owa", this.OwaThrottlingPolicyStateSettings); LegacyThrottlingPolicy.AppendSettingsString(stringBuilder, "Pop", this.PopThrottlingPolicyStateSettings); LegacyThrottlingPolicy.AppendSettingsString(stringBuilder, "Imap", this.ImapThrottlingPolicyStateSettings); LegacyThrottlingPolicy.AppendSettingsString(stringBuilder, "PowerShell", this.PowershellThrottlingPolicyStateSettings); LegacyThrottlingPolicy.AppendSettingsString(stringBuilder, "Rca", this.RcaThrottlingPolicyStateSettings); LegacyThrottlingPolicy.AppendSettingsString(stringBuilder, "General", this.GeneralThrottlingPolicyStateSettings); return(stringBuilder.ToString()); }
internal void CloneThrottlingSettingsTo(LegacyThrottlingPolicy policy) { policy.AnonymousThrottlingPolicyStateSettings = this.AnonymousThrottlingPolicyStateSettings; policy.EasThrottlingPolicyStateSettings = this.EasThrottlingPolicyStateSettings; policy.EwsThrottlingPolicyStateSettings = this.EwsThrottlingPolicyStateSettings; policy.ImapThrottlingPolicyStateSettings = this.ImapThrottlingPolicyStateSettings; policy.OwaThrottlingPolicyStateSettings = this.OwaThrottlingPolicyStateSettings; policy.PopThrottlingPolicyStateSettings = this.PopThrottlingPolicyStateSettings; policy.PowershellThrottlingPolicyStateSettings = this.PowershellThrottlingPolicyStateSettings; policy.RcaThrottlingPolicyStateSettings = this.RcaThrottlingPolicyStateSettings; policy.GeneralThrottlingPolicyStateSettings = this.GeneralThrottlingPolicyStateSettings; if (policy.Session == null) { policy.m_Session = base.Session; } }
internal static LegacyThrottlingPolicy GetLegacyThrottlingPolicy(ThrottlingPolicy policy) { LegacyThrottlingPolicy legacyThrottlingPolicy; if (policy.ObjectState == ObjectState.New) { legacyThrottlingPolicy = new LegacyThrottlingPolicy(); legacyThrottlingPolicy[ADObjectSchema.ObjectState] = ObjectState.Unchanged; legacyThrottlingPolicy.ResetChangeTracking(); } else { legacyThrottlingPolicy = LegacyThrottlingPolicy.LoadLegacyThrottlingPolicyFromAD(policy); } return(legacyThrottlingPolicy); }