|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object uk.ac.leeds.ccg.andyt.grids.utilities.ErrorHandler
public abstract class ErrorHandler
A class to be extended by classes that handle runtime errors such as java.lang.OutOfMemroyError TODO: Add a constant int TYPE which can be used to switch between different types of this. Handling for NumberFormatExceptions and ArithmeticExceptions in calculations
Field Summary | |
---|---|
static boolean |
handleOutOfMemoryErrorFalse
|
static boolean |
handleOutOfMemoryErrorTrue
|
protected int[] |
memoryReserve
Reserve memory to be cleared when dealing with java.lang.OutOfMemoryErrors. |
Constructor Summary | |
---|---|
ErrorHandler()
|
Method Summary | |
---|---|
void |
clearMemoryReserve()
Clears memoryReserve by setting it to null and calling the garbage collector. |
void |
initMemoryReserve()
Initialises memoryReserve as an array of size 2000000. |
void |
initMemoryReserve(int size)
Initialises memoryReserve as an array of size. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final boolean handleOutOfMemoryErrorFalse
public static final boolean handleOutOfMemoryErrorTrue
protected int[] memoryReserve
Constructor Detail |
---|
public ErrorHandler()
Method Detail |
---|
public final void initMemoryReserve(int size)
size
- The size that memoryReserve is initialised to.public final void initMemoryReserve()
public final void clearMemoryReserve()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |