final Object value = objectAdapter.getObject();
final String label;
if(value instanceof Clob) {
final Clob clob = (Clob) value;
ResourceStreamRequestHandler handler =
new ResourceStreamRequestHandler(new StringResourceStream(clob.getChars(), clob.getMimeType().toString()), clob.getName());
handler.setContentDisposition(ContentDisposition.ATTACHMENT);
getRequestCycle().scheduleRequestHandlerAfterCurrent(handler);
label = "Downloading: " + clob.getName();
} else if(value instanceof Blob) {
final Blob blob = (Blob) value;
ResourceRequestHandler handler =