SpatialProductBinner { static float[] getSuperSamplingSteps(Integer superSampling) { if (superSampling == null || superSampling <= 1) { return new float[]{0.5f}; } else { float[] samplingStep = new float[superSampling]; for (int i = 0; i < samplingStep.length; i++) { samplingStep[i] = (i * 2.0F + 1.0F) / (2.0F * superSampling); } return samplingStep; } }  static long processProduct(Product product,
                                      SpatialBinner spatialBinner,
                                      Map<Product, List<Band>> addedVariableBands,
                                      ProgressMonitor progressMonitor);  }
@Test public void testGetSuperSamplingSteps() { float[] superSamplingSteps = SpatialProductBinner.getSuperSamplingSteps(1); assertNotNull(superSamplingSteps); assertEquals(1, superSamplingSteps.length); assertEquals(0.5f, superSamplingSteps[0], 0.0001); superSamplingSteps = SpatialProductBinner.getSuperSamplingSteps(2); assertNotNull(superSamplingSteps); assertEquals(2, superSamplingSteps.length); assertEquals(0.25f, superSamplingSteps[0], 0.0001); assertEquals(0.75f, superSamplingSteps[1], 0.0001); superSamplingSteps = SpatialProductBinner.getSuperSamplingSteps(3); assertNotNull(superSamplingSteps); assertEquals(3, superSamplingSteps.length); assertEquals(1f / 6, superSamplingSteps[0], 0.0001); assertEquals(3f / 6, superSamplingSteps[1], 0.0001); assertEquals(5f / 6, superSamplingSteps[2], 0.0001); }