class HttpServletResponseImpl implements HttpServletResponse {

    @Override
    public PrintWriter getWriter() {
        if (printWriter == null) {
            if (isTransferChunked()) {
                printWriter = new ChunkedPrintWriter(wrappedOutputStream);
            } else {
                printWriter = new ServletPrintWriter(wrappedOutputStream);
            }
        }

        return printWriter;
    }

    public  HttpServletResponseImpl(final Serializer<Headers> headersSerializer,
                                   final Serializer<Cookie> cookieHeaderSerializer,
                                   final StreamHelper streamHelper,
                                   final OutputStream outputStream);

}