cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Reinhard Poetz <reinh...@apache.org>
Subject ServletSource#getInputStream()
Date Tue, 01 Jan 2008 20:26:08 GMT

Can somebody explain the purpose of this code to me? What's the use case that 
makes a second request necessary?

public InputStream getInputStream() throws IOException,
     SourceException {
     try {
         connect();
         if (servletConnection.getResponseCode() != HttpServletResponse.SC_OK) {
           ... redo the request here ...
         }

         return this.servletConnection.getInputStream();
     } catch (ServletException e) {
         throw new CascadingIOException(e.getMessage(), e);
     }
}

Thanks!

-- 
Reinhard Pötz                            Managing Director, {Indoqa} GmbH
                           http://www.indoqa.com/en/people/reinhard.poetz/

Member of the Apache Software Foundation
Apache Cocoon Committer, PMC member, PMC Chair        reinhard@apache.org
_________________________________________________________________________

Mime
View raw message