I have some classes that need a bunch of data tables to do their work (basically arrays of primitives, byte[], short[], int[] and float[]).
Some of the tables are relatively large. Initializing them in the code blows up the class file, and in some cases it also exceeds the size limit for the class initializer.
Currently i have stored the data in files and use getResourceAsStream() to read the files in a static block.
Is there a better way that makes the data inseparable from the class file? There is no need to ever replace the data independently from the class.