public class UUID
{
private static int currentValue = 一;
private static final int maxValue = 99999;
private UUID()
{
}
private static int getInt()
{
if (currentValue == maxValue)
{
currentValue = 一;
return maxValue;
}
return currentValue++;
}
public static synchronized String getUUID()
{
//可以用十六进制来搞
String k = Integer.toString(getInt());
while(k.length()<五)
{
k= "零" + k;
}
return k;
}
}
本文来源:
我的异常网
Java Exception
Dotnet Exception
Oracle Exception
- 2120 - java.lang.NoClassDefFoundError
- 2121 - java.lang.NullPointerException
- 2122 - java.lang.ClassNotFoundException
- 2123 - html:errors
- 2124 - java.lang.OutOfMemoryError
- 2125 - org.apache.jasper.JasperException
- 2126 - java.lang.IllegalArgumentException
- 2127 - javax.servlet.ServletException
- 2128 - java.lang.ExceptionInInitializerError
- 2129 - java.lang.ClassCastException
- 2130 - java.lang.NoSuchMethodError
- 2131 - java.net.SocketException
- 2132 - 空指针异常
- 2133 - net.sf.hibernate.MappingException
- 2134 - java.lang.ArrayIndexOutOfBoundsException
- 2135 - org.apache.commons.dbcp.SQLNestedException