code: private boolean checkLoadConsistency() {
          boolean check = true;
          int[][] rs = new int[nbDims][nbBins];
          int[][] cs = new int[nbDims][nbBins];
          for (int i = 0; i < bins.length; i++) {
              if (bins[i].isInstantiated()) {
                  for (int d = 0; d < nbDims; d++) {
                      rs[d][bins[i].getValue()] += iSizes[d][i];
                  }
              } else {
                  DisposableValueIterator it = bins[i].getValueIterator(true);
                  try {
                      while (it.hasNext()) {
                          int v = it.next();
                          for (int d = 0; d < nbDims; d++) {
                              cs[d][v] += iSizes[d][i];
                          }
                      }
                  } finally {
                      it.dispose();
                  }
              }
          }
  
          for (int d = 0; d < nbDims; d++) {
              check = check && checkDimension(d, rs, cs);
          }
          if (!check) {
              for (IntVar v : bins) {
                  System.out.println(v.toString());
              }
          }
          return check;
      }
docs: Check the consistency of the assigned and candidate loads with regards to the assignment variables:
  for each bin: sumAssignedItemSizes == binAssignedLoad, sumAllPossibleItemSizes == binPotentialLoad
  rule 2, for each bin: binAssignedLoad <= binLoad <= binPotentialLoad
  
  @return {@code false} if not consistent.