final Cell cell = cella[0][rj][cj];
double num = 0d;
if (cell != null) {
final Object val = cell.getResult();
if (val instanceof SSError) {
throw new SSErrorXelException((SSError)val);
} else if (val instanceof Number) {
num = ((Number)val).doubleValue();
}
}
vala[rj][cj] = num;
}
}
return vala;
} else if (arg instanceof Object[][]){ //constant array, returned by utilArray
final Object[][] obja = (Object[][]) arg;
final int rowsz = obja.length;
final int colsz = obja[0].length;
final double[][] vala = new double[rowsz][];
for (int rj = 0; rj < colsz; ++rj) {
vala[rj] = new double[colsz];
for (int cj = 0; cj < colsz; ++cj) {
final Object val = obja[rj][cj];
double num = 0d;
if (val != null) {
if (val instanceof SSError) {
throw new SSErrorXelException((SSError)val);
} else if (val instanceof Number) {
num = ((Number)val).doubleValue();
}
}
vala[rj][cj] = num;
}
}
return vala;
}
throw new SSErrorXelException(SSError.VALUE);
}