@Override
public RowSet getUDTs(ServiceMetaDataArgs args, List<SnappyType> types)
throws SnappyException {
ResultSet rs = null;
try {
final ConnectionHolder connHolder = getValidConnection(args.connId,
args.token);
EmbedDatabaseMetaData dmd = (EmbedDatabaseMetaData)connHolder
.getConnection().getMetaData();
int[] sqlTypes = null;
if (types != null && !types.isEmpty()) {
sqlTypes = new int[types.size()];
for (int index = 0; index < types.size(); index++) {
sqlTypes[index] = Converters.getJdbcType(types.get(index));
}
}
rs = dmd.getUDTs(null, args.getSchema(), args.getTypeName(), sqlTypes);
return getRowSet(null, null, rs, INVALID_ID, null, args.connId, null, 0,
false, false, 0, connHolder, "getUDTs");
} catch (Throwable t) {
cleanupResultSet(rs);
checkSystemFailure(t);
throw SnappyException(t);
}
}