Package org.actioncontroller.socket
Class HttpMessage
- java.lang.Object
-
- org.actioncontroller.socket.HttpMessage
-
public class HttpMessage extends Object
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Optional<String>firstHeader(String name)Map<String,List<String>>getAllHeaders()List<String>getHeaders(String name)InputStreamgetInputStream(InputStream inputStream)ReadergetReader(InputStream inputStream)List<String>getRequestCookies(String name)List<ActionControllerCookie>getResponseCookies()StringgetStartLine()static HttpMessageread(InputStream inputStream)byte[]readBodyBytes(InputStream inputStream)StringreadBodyString(InputStream inputStream)static Map<String,List<String>>readHttpHeaders(InputStream inputStream)static StringreadLine(InputStream inputStream)
-
-
-
Method Detail
-
read
public static HttpMessage read(InputStream inputStream) throws IOException
- Throws:
IOException
-
getStartLine
public String getStartLine()
-
getInputStream
public InputStream getInputStream(InputStream inputStream) throws IOException
- Throws:
IOException
-
readBodyBytes
public byte[] readBodyBytes(InputStream inputStream) throws IOException
- Throws:
IOException
-
readBodyString
public String readBodyString(InputStream inputStream) throws IOException
- Throws:
IOException
-
getReader
public Reader getReader(InputStream inputStream) throws IOException
- Throws:
IOException
-
readHttpHeaders
public static Map<String,List<String>> readHttpHeaders(InputStream inputStream) throws IOException
- Throws:
IOException
-
readLine
public static String readLine(InputStream inputStream) throws IOException
- Throws:
IOException
-
getResponseCookies
public List<ActionControllerCookie> getResponseCookies()
-
-