@@ -43,15 +43,15 @@ public void write(long[] offset, ucar.ma2.Array array, boolean parallel) {
4343 int [] shape = array .getShape ();
4444
4545 final int [] chunkShape = metadata .chunkShape ();
46- Stream <long []> chunkStream = Arrays .stream (IndexingUtils .computeChunkCoords (metadata .shape () , chunkShape , offset , shape ));
46+ Stream <long []> chunkStream = Arrays .stream (IndexingUtils .computeChunkCoords (metadata .shape , chunkShape , offset , shape ));
4747 if (parallel ) {
4848 chunkStream = chunkStream .parallel ();
4949 }
5050 chunkStream .forEach (
5151 chunkCoords -> {
5252 try {
5353 final IndexingUtils .ChunkProjection chunkProjection =
54- IndexingUtils .computeProjection (chunkCoords , metadata .shape () , chunkShape , offset ,
54+ IndexingUtils .computeProjection (chunkCoords , metadata .shape , chunkShape , offset ,
5555 shape
5656 );
5757
@@ -169,7 +169,7 @@ public void write(ucar.ma2.Array array, boolean parallel) {
169169 */
170170 @ Nonnull
171171 public ucar .ma2 .Array read () throws ZarrException {
172- return read (new long [metadata ().ndim ()], Utils .toIntArray (metadata ().shape () ));
172+ return read (new long [metadata ().ndim ()], Utils .toIntArray (metadata ().shape ));
173173 }
174174
175175 /**
@@ -193,14 +193,14 @@ public ucar.ma2.Array read(final long[] offset, final int[] shape) throws ZarrEx
193193 */
194194 @ Nonnull
195195 public ucar .ma2 .Array read (final boolean parallel ) throws ZarrException {
196- return read (new long [metadata ().ndim ()], Utils .toIntArray (metadata ().shape () ), parallel );
196+ return read (new long [metadata ().ndim ()], Utils .toIntArray (metadata ().shape ), parallel );
197197 }
198198
199199 boolean chunkIsInArray (long [] chunkCoords ) {
200200 final int [] chunkShape = metadata ().chunkShape ();
201201 for (int dimIdx = 0 ; dimIdx < metadata ().ndim (); dimIdx ++) {
202202 if (chunkCoords [dimIdx ] < 0
203- || chunkCoords [dimIdx ] * chunkShape [dimIdx ] >= metadata ().shape () [dimIdx ]) {
203+ || chunkCoords [dimIdx ] * chunkShape [dimIdx ] >= metadata ().shape [dimIdx ]) {
204204 return false ;
205205 }
206206 }
@@ -225,7 +225,7 @@ public ucar.ma2.Array read(final long[] offset, final int[] shape, final boolean
225225 throw new IllegalArgumentException ("'shape' needs to have rank '" + metadata .ndim () + "'." );
226226 }
227227 for (int dimIdx = 0 ; dimIdx < metadata .ndim (); dimIdx ++) {
228- if (offset [dimIdx ] < 0 || offset [dimIdx ] + shape [dimIdx ] > metadata .shape () [dimIdx ]) {
228+ if (offset [dimIdx ] < 0 || offset [dimIdx ] + shape [dimIdx ] > metadata .shape [dimIdx ]) {
229229 throw new ZarrException ("Requested data is outside of the array's domain." );
230230 }
231231 }
@@ -237,15 +237,15 @@ public ucar.ma2.Array read(final long[] offset, final int[] shape, final boolean
237237
238238 final ucar .ma2 .Array outputArray = ucar .ma2 .Array .factory (metadata .dataType ().getMA2DataType (),
239239 shape );
240- Stream <long []> chunkStream = Arrays .stream (IndexingUtils .computeChunkCoords (metadata .shape () , chunkShape , offset , shape ));
240+ Stream <long []> chunkStream = Arrays .stream (IndexingUtils .computeChunkCoords (metadata .shape , chunkShape , offset , shape ));
241241 if (parallel ) {
242242 chunkStream = chunkStream .parallel ();
243243 }
244244 chunkStream .forEach (
245245 chunkCoords -> {
246246 try {
247247 final IndexingUtils .ChunkProjection chunkProjection =
248- IndexingUtils .computeProjection (chunkCoords , metadata .shape () , chunkShape , offset ,
248+ IndexingUtils .computeProjection (chunkCoords , metadata .shape , chunkShape , offset ,
249249 shape
250250 );
251251
0 commit comments