} else if (Object[].class.isAssignableFrom(val.getClass())) {
this.model = new ArrayDataModel((Object[]) val);
} else if (val instanceof ResultSet) {
this.model = new ResultSetDataModel((ResultSet) val);
} else {
this.model = new ScalarDataModel(val);
}
}
return this.model;
}