code: public static ResultSet triangleContouring(Connection connection, String tableName, Value... varArgs) throws SQLException {
          if (connection.getMetaData().getURL().equals(HACK_URL)) {
              return new ExplodeResultSet(connection,tableName, Collections.singletonList(0.0)).getResultSet();
          }
          ExplodeResultSet rowSource = null;
          if(varArgs.length > 3) {
              // First ones may be column names
              if(varArgs[0] instanceof ValueString &&
                      varArgs[1] instanceof ValueString &&
                      varArgs[2] instanceof ValueString) {
                  // Use table columns for iso levels
                  List<Double> isoLvls = new ArrayList<Double>(varArgs.length - 3);
                  for(int idArg = 3; idArg < varArgs.length; idArg++) {
                      isoLvls.add(varArgs[idArg].getDouble());
                  }
                  rowSource = new ExplodeResultSet(connection,tableName,varArgs[0].getString(), varArgs[1].getString(),
                          varArgs[2].getString(), isoLvls);
              }
          }
          if(rowSource == null) {
              // Use Z
              List<Double> isoLvls = new ArrayList<Double>(varArgs.length);
              for (Value value : varArgs) {
                  if (value instanceof ValueArray) {
                      for (Value arrVal : ((ValueArray) value).getList()) {
                          isoLvls.add(arrVal.getDouble());
                      }
                  } else {
                      isoLvls.add(value.getDouble());
                  }
              }
              rowSource = new ExplodeResultSet(connection,tableName, isoLvls);
          }
          return rowSource.getResultSet();
      }
docs: Iso contouring using Z,M attributes of geometries
  @param connection Active connection
  @param tableName Table name
  @param varArgs Iso levels
  @return Result Set
  @throws SQLException