code: private void fillServletResponse(ODataResponse oDataResponse, HttpServletResponse servletResponse)
              throws IOException, ODataException {
          servletResponse.setStatus(oDataResponse.getStatus().getCode());
  
          for (Map.Entry<String, String> entry : oDataResponse.getHeaders().entrySet()) {
              servletResponse.setHeader(entry.getKey(), entry.getValue());
          }
  
          byte[] body = oDataResponse.getBody();
          if (body != null && body.length != 0) {
              OutputStream out = servletResponse.getOutputStream();
              out.write(oDataResponse.getBody());
              out.flush();
          } else if (oDataResponse.getStreamingContent() != null) {
              oDataResponse.getStreamingContent().write(servletResponse);
          }
      }
docs: Transfers data from an {@code ODataResponse} into an {@code HttpServletResponse}.
  
  @param oDataResponse   The {@code ODataResponse}.
  @param servletResponse The {@code HttpServletResponse}
  @throws java.io.IOException If an I/O error occurs.