Reading-eScience-Centre / edal-java

Environmental Data Abstraction Layer libraries
Other
39 stars 30 forks source link

Usage of Array2D and Array4D unclear #25

Open letmaik opened 9 years ago

letmaik commented 9 years ago

In GridFeature there's the method Array4D<Number> getValues(String paramId), however as Array4D is supposed to be a generic 4D array (even though it has some convenience methods like getTSize which suggest otherwise) there has to be javadoc which says which array dimension corresponds to which domain axis. Alternatively, the Array* classes can be made specific and explicitly state that e.g. Array4D must always contain data where the axes are T,Z,Y,X and correspond to time, depth, horizontal pos. Since the Array1D is used for different axis types I suggest the former approach and remove the convenience methods which point to specific axis semantics.