I have an app that get ftp disk space. so space given by a number that present how many bytes.
the problem is when i got space over 39.4 GB i can just store 39.4*1024*1024*1024 in a long or double var. so if you have 50 GB it just show you 39.4. whats the solution?
See if BigInteger class helps you with your problem
http://download.oracle.com/javase/6/docs/api/java/math/BigInteger.html
EDIT:
Actually as others already mentioned, long value will be able to hold a really big value, it can hold far more than 40gb as a number value