internal static void AddUserPolicy(string login, string username, string[] permissions, SPWebApplication webApp, SPUrlZone[] zones)
 {
     foreach (SPUrlZone zone in zones)
     {
         AddUserPolicy(login, username, permissions, webApp, webApp.ZonePolicies(zone));
     }
 }
 /// <summary>
 /// Gets the zone policy collection.
 /// </summary>
 /// <param name="zoneName">Name of the zone.</param>
 /// <param name="application">The application.</param>
 /// <returns></returns>
 internal static SPPolicyCollection GetZonePolicyCollection(string zoneName, SPWebApplication application)
 {
     zoneName = zoneName.ToLowerInvariant();
     return (!zoneName.Equals("all") ? application.ZonePolicies((SPUrlZone)Enum.Parse(typeof(SPUrlZone), zoneName, true)) : application.Policies);
 }
 internal static void AddUserPolicy(string login, string username, string[] permissions, SPWebApplication webApp, SPUrlZone[] zones)
 {
     foreach (SPUrlZone zone in zones)
         AddUserPolicy(login, username, permissions, webApp, webApp.ZonePolicies(zone));
 }
 /// <summary>
 /// Gets the zone policy collection.
 /// </summary>
 /// <param name="zoneName">Name of the zone.</param>
 /// <param name="application">The application.</param>
 /// <returns></returns>
 internal static SPPolicyCollection GetZonePolicyCollection(string zoneName, SPWebApplication application)
 {
     zoneName = zoneName.ToLowerInvariant();
     return(!zoneName.Equals("all") ? application.ZonePolicies((SPUrlZone)Enum.Parse(typeof(SPUrlZone), zoneName, true)) : application.Policies);
 }