com.partnersoft.data
Class ByteSize
java.lang.Object
com.partnersoft.data.ByteSize
- All Implemented Interfaces:
- Immutable
public class ByteSize
- extends java.lang.Object
- implements Immutable
An immutable measure that allows you to specify a byte size in a variety of
ways and get it back in whatever units you want.
Copyright 2008 Partner Software, Inc.
- Version:
- $Id$
- Author:
- Paul Reavis
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
forBytes
public static ByteSize forBytes(long bytes)
forBytes
public static ByteSize forBytes(double bytes)
forKilobytes
public static ByteSize forKilobytes(long kb)
forKilobytes
public static ByteSize forKilobytes(double kb)
forMegabytes
public static ByteSize forMegabytes(long mb)
forMegabytes
public static ByteSize forMegabytes(double mb)
forGigabytes
public static ByteSize forGigabytes(int gb)
forGigabytes
public static ByteSize forGigabytes(double gb)
forTerabytes
public static ByteSize forTerabytes(int tb)
forTerabytes
public static ByteSize forTerabytes(double tb)
getBytes
public long getBytes()
getKilobytes
public double getKilobytes()
getMegabytes
public double getMegabytes()
getGigabytes
public double getGigabytes()
getTerabytes
public double getTerabytes()