Methods Summary |
---|
public java.lang.Object | buildObject(oracle.toplink.essentials.internal.sessions.AbstractRecord row)INTERNAL:
Used by cursored stream.
Return the first field in the row.
Object value = row.get(row.getFields().firstElement());
if (getValueConverter() != null) {
value = getValueConverter().convertDataValueToObjectValue(value, session);
}
return value;
|
public java.lang.Object | executeNonCursor()INTERNAL:
The results are *not* in a cursor, build the collection.
ContainerPolicy cp = getContainerPolicy();
Vector rows = getQueryMechanism().executeSelect();
Object result = cp.containerInstance(rows.size());
DatabaseField resultDirectField = null;
for (Enumeration stream = rows.elements(); stream.hasMoreElements();) {
AbstractRecord row = (AbstractRecord)stream.nextElement();
if (resultDirectField == null) {
resultDirectField = (DatabaseField)row.getFields().firstElement();
}
Object value = row.get(resultDirectField);
if (getValueConverter() != null) {
value = getValueConverter().convertDataValueToObjectValue(value, session);
}
cp.addInto(value, result, getSession());
}
return result;
|
public oracle.toplink.essentials.mappings.converters.Converter | getValueConverter()PUBLIC:
Return the converter on the query.
A converter can be used to convert between the result value and database value.
return valueConverter;
|
public void | setValueConverter(oracle.toplink.essentials.mappings.converters.Converter valueConverter)PUBLIC:
Set the converter on the query.
A converter can be used to convert between the result value and database value.
this.valueConverter = valueConverter;
|