I'm not quite what you are asking for, because when you say "list classes", it makes me think of iterating over the properties of objects using reflection; that this is not what you want to do.
For me, it is more like your 3D array should contain objects, not integers. If you have a Voxel base class that inherits all voxels from you, remove the need for a type specifier. Instead, you simply put the abstract methods in the base class and override them in the derived classes. After you have all this, any code dealing with an array should be able to interact with it without knowing the type of the derived class.
The application code should just view it as an array of type Voxel . Invocation methods for any given Voxel must perform behavior specific to this type of voxel. This is the basic idea of inheritance and polymorphism.
source share