org.apfloat.internal
Class DoubleDataStorageBuilder
java.lang.Object
org.apfloat.internal.DoubleDataStorageBuilder
- All Implemented Interfaces:
- DataStorageBuilder
public class DoubleDataStorageBuilder
- extends Object
- implements DataStorageBuilder
Default data storage creation strategy for the double data type.
- Version:
- 1.0
- Author:
- Mikko Tommila
- See Also:
DoubleMemoryDataStorage,
DoubleDiskDataStorage
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DoubleDataStorageBuilder
public DoubleDataStorageBuilder()
- Default constructor.
createDataStorage
public DataStorage createDataStorage(long size)
throws ApfloatRuntimeException
- Description copied from interface:
DataStorageBuilder
- Get an appropriate type of data storage for the requested size of data.
Note that the returned data storage object is not set to have the
requested size, so the client should call the object's DataStorage.setSize(long)
method before storing data to it.
- Specified by:
createDataStorage in interface DataStorageBuilder
- Parameters:
size - The size of data to be stored in the storage, in bytes.
- Returns:
- An empty
DataStorage object of an appropriate type for storing size bytes of data.
- Throws:
ApfloatRuntimeException