001 package railo.commons.net.http; 002 003 import java.io.IOException; 004 import java.io.InputStream; 005 import java.net.URL; 006 007 import railo.commons.io.res.ContentType; 008 009 public interface HTTPResponse { 010 011 public String getContentAsString() throws IOException; 012 013 public String getContentAsString(String charset) throws IOException; 014 015 public InputStream getContentAsStream() throws IOException; 016 017 public byte[] getContentAsByteArray() throws IOException; 018 019 public ContentType getContentType(); 020 021 public Header getLastHeader(String name); 022 023 public Header getLastHeaderIgnoreCase(String name); 024 025 public String getCharset(); 026 027 public long getContentLength() throws IOException; 028 029 public URL getURL(); 030 031 public int getStatusCode(); 032 033 public String getStatusText(); 034 035 public String getProtocolVersion(); 036 037 public String getStatusLine(); 038 039 public Header[] getAllHeaders(); 040 }