com.go.trove.net
Class HttpUtils

java.lang.Object
  |
  +--com.go.trove.net.HttpUtils

public class HttpUtils
extends java.lang.Object

Version:
2 , 01/04/03
Author:
Brian S O'Neill

Constructor Summary
HttpUtils()
           
 
Method Summary
static java.lang.String readLine(java.io.InputStream in, byte[] buffer)
          Reads a line from an HTTP InputStream, using the given buffer for temporary storage.
static java.lang.String readLine(java.io.InputStream in, byte[] buffer, int limit)
          Reads a line from an HTTP InputStream, using the given buffer for temporary storage.
static java.lang.String readLine(java.io.InputStream in, char[] buffer)
          Reads a line from an HTTP InputStream, using the given buffer for temporary storage.
static java.lang.String readLine(java.io.InputStream in, char[] buffer, int limit)
          Reads a line from an HTTP InputStream, using the given buffer for temporary storage.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HttpUtils

public HttpUtils()
Method Detail

readLine

public static java.lang.String readLine(java.io.InputStream in,
                                        byte[] buffer)
                                 throws java.lang.IllegalArgumentException,
                                        java.io.IOException
Reads a line from an HTTP InputStream, using the given buffer for temporary storage.
Parameters:
in - stream to read from
buffer - temporary buffer to use
Throws:
java.lang.IllegalArgumentException - if the given InputStream doesn't support marking

readLine

public static java.lang.String readLine(java.io.InputStream in,
                                        byte[] buffer,
                                        int limit)
                                 throws java.lang.IllegalArgumentException,
                                        java.io.IOException,
                                        LineTooLongException
Reads a line from an HTTP InputStream, using the given buffer for temporary storage.
Parameters:
in - stream to read from
buffer - temporary buffer to use
Throws:
java.lang.IllegalArgumentException - if the given InputStream doesn't support marking
LineTooLongException - when line is longer than the limit

readLine

public static java.lang.String readLine(java.io.InputStream in,
                                        char[] buffer)
                                 throws java.lang.IllegalArgumentException,
                                        java.io.IOException
Reads a line from an HTTP InputStream, using the given buffer for temporary storage.
Parameters:
in - stream to read from
buffer - temporary buffer to use
Throws:
java.lang.IllegalArgumentException - if the given InputStream doesn't support marking

readLine

public static java.lang.String readLine(java.io.InputStream in,
                                        char[] buffer,
                                        int limit)
                                 throws java.lang.IllegalArgumentException,
                                        java.io.IOException,
                                        LineTooLongException
Reads a line from an HTTP InputStream, using the given buffer for temporary storage.
Parameters:
in - stream to read from
buffer - temporary buffer to use
Throws:
java.lang.IllegalArgumentException - if the given InputStream doesn't support marking
LineTooLongException - when line is longer than the limit