org.apache.velocity.test

Class VelocityServletTest.MockHttpServletResponse

Enclosing Class:
VelocityServletTest
Implemented Interfaces:
HttpServletResponse

(package private) static class VelocityServletTest.MockHttpServletResponse
extends java.lang.Object
implements HttpServletResponse

Field Summary

private String
encoding

Method Summary

void
addCookie(javax.servlet.http.Cookie c)
void
addDateHeader(String s, long l)
void
addHeader(String name, String value)
void
addIntHeader(String name, int value)
boolean
containsHeader(String name)
String
encodeRedirectURL(String url)
String
encodeRedirectUrl(String url)
String
encodeURL(String url)
String
encodeUrl(String url)
void
flushBuffer()
int
getBufferSize()
String
getCharacterEncoding()
String
getContentType()
java.util.Locale
getLocale()
javax.servlet.ServletOutputStream
getOutputStream()
java.io.PrintWriter
getWriter()
boolean
isCommitted()
void
reset()
void
resetBuffer()
void
sendError(int i)
void
sendError(int i, String s)
void
sendRedirect(String s)
void
setBufferSize(int i)
void
setCharacterEncoding(String charset)
void
setContentLength(int i)
void
setContentType(String contentType)
Records the character encoding.
void
setDateHeader(String s, long l)
void
setHeader(String name, String value)
void
setIntHeader(String s, int i)
void
setLocale(java.util.Locale l)
void
setStatus(int i)
void
setStatus(int i, String s)

Field Details

encoding

private String encoding

Method Details

addCookie

public void addCookie(javax.servlet.http.Cookie c)

addDateHeader

public void addDateHeader(String s,
                          long l)

addHeader

public void addHeader(String name,
                      String value)

addIntHeader

public void addIntHeader(String name,
                         int value)

containsHeader

public boolean containsHeader(String name)

encodeRedirectURL

public String encodeRedirectURL(String url)

encodeRedirectUrl

public String encodeRedirectUrl(String url)

encodeURL

public String encodeURL(String url)

encodeUrl

public String encodeUrl(String url)

flushBuffer

public void flushBuffer()
            throws IOException

getBufferSize

public int getBufferSize()

getCharacterEncoding

public String getCharacterEncoding()

getContentType

public String getContentType()

getLocale

public java.util.Locale getLocale()

getOutputStream

public javax.servlet.ServletOutputStream getOutputStream()
            throws IOException

getWriter

public java.io.PrintWriter getWriter()
            throws IOException

isCommitted

public boolean isCommitted()

reset

public void reset()

resetBuffer

public void resetBuffer()

sendError

public void sendError(int i)
            throws IOException

sendError

public void sendError(int i,
                      String s)
            throws IOException

sendRedirect

public void sendRedirect(String s)
            throws IOException

setBufferSize

public void setBufferSize(int i)

setCharacterEncoding

public void setCharacterEncoding(String charset)

setContentLength

public void setContentLength(int i)

setContentType

public void setContentType(String contentType)
Records the character encoding.

setDateHeader

public void setDateHeader(String s,
                          long l)

setHeader

public void setHeader(String name,
                      String value)

setIntHeader

public void setIntHeader(String s,
                         int i)

setLocale

public void setLocale(java.util.Locale l)

setStatus

public void setStatus(int i)

setStatus

public void setStatus(int i,
                      String s)

Copyright B) 2002 Apache Software Foundation. All Rights Reserved.