/// <summary>
 /// 获取下一下Ip地址
 /// </summary>
 /// <param name="ip"></param>
 /// <returns></returns>
 public static IPAddress GetNextValid(this IPAddress ip)
 {
     while (true)
     {
         ip = ip.Add(1);
         if (ip.IsValid() == true)
         {
             return(ip);
         }
     }
 }
Ejemplo n.º 2
0
 public static IPAddress GetPreviousIPAddress(this IPAddress ipAddress)
 {
     return(ipAddress.Add(-1));
 }