wr.write(content);
wr.flush();
wr.close();
}
} else {
CRException crex = new CRException("NoDataFound", "Data could not be found.", ERRORTYPE.NO_DATA_FOUND);
this.respondWithError(stream, crex, myReqBuilder.isDebug());
}
stream.flush();
stream.close();
} catch (CRException e1) {
this.contenttype = "text/html; charset=" + this.responseEncoding;
respondWithError((OutputStream) stream, e1, myReqBuilder.isDebug());
e1.printStackTrace();
} catch (Exception e) {
log.error("Error while processing service " + "(RESTBinaryContainer)", e);
CRException crex = new CRException(e);
this.respondWithError(stream, crex, myReqBuilder.isDebug());
}
}