[java] How to implement infinity in Java?