001: /*
002: * All content copyright (c) 2003-2006 Terracotta, Inc., except as may otherwise be noted in a separate copyright notice. All rights reserved.
003: */
004: package javax.servlet.http;
005:
006: import com.tc.exception.ImplementMe;
007:
008: import java.io.PrintWriter;
009: import java.util.ArrayList;
010: import java.util.Locale;
011:
012: import javax.servlet.ServletOutputStream;
013:
014: public class MockHttpServletResponse implements HttpServletResponse {
015:
016: private ArrayList cookies = new ArrayList();
017:
018: public void addCookie(Cookie arg0) {
019: cookies.add(arg0);
020: }
021:
022: public void addDateHeader(String arg0, long arg1) {
023: throw new ImplementMe();
024:
025: }
026:
027: public void addHeader(String arg0, String arg1) {
028: throw new ImplementMe();
029:
030: }
031:
032: public void addIntHeader(String arg0, int arg1) {
033: throw new ImplementMe();
034:
035: }
036:
037: public boolean containsHeader(String arg0) {
038: throw new ImplementMe();
039: }
040:
041: public String encodeRedirectURL(String arg0) {
042: throw new ImplementMe();
043: }
044:
045: public String encodeRedirectUrl(String arg0) {
046: throw new ImplementMe();
047: }
048:
049: public String encodeURL(String arg0) {
050: throw new ImplementMe();
051: }
052:
053: public String encodeUrl(String arg0) {
054: throw new ImplementMe();
055: }
056:
057: public void sendError(int arg0) {
058: throw new ImplementMe();
059:
060: }
061:
062: public void sendError(int arg0, String arg1) {
063: throw new ImplementMe();
064:
065: }
066:
067: public void sendRedirect(String arg0) {
068: throw new ImplementMe();
069:
070: }
071:
072: public void setDateHeader(String arg0, long arg1) {
073: throw new ImplementMe();
074:
075: }
076:
077: public void setHeader(String arg0, String arg1) {
078: throw new ImplementMe();
079:
080: }
081:
082: public void setIntHeader(String arg0, int arg1) {
083: throw new ImplementMe();
084:
085: }
086:
087: public void setStatus(int arg0) {
088: throw new ImplementMe();
089:
090: }
091:
092: public void setStatus(int arg0, String arg1) {
093: throw new ImplementMe();
094:
095: }
096:
097: public void flushBuffer() {
098: throw new ImplementMe();
099:
100: }
101:
102: public int getBufferSize() {
103: throw new ImplementMe();
104: }
105:
106: public String getCharacterEncoding() {
107: throw new ImplementMe();
108: }
109:
110: public String getContentType() {
111: throw new ImplementMe();
112: }
113:
114: public Locale getLocale() {
115: throw new ImplementMe();
116: }
117:
118: public ServletOutputStream getOutputStream() {
119: throw new ImplementMe();
120: }
121:
122: public PrintWriter getWriter() {
123: throw new ImplementMe();
124: }
125:
126: public boolean isCommitted() {
127: return false;
128: }
129:
130: public void reset() {
131: throw new ImplementMe();
132:
133: }
134:
135: public void resetBuffer() {
136: throw new ImplementMe();
137:
138: }
139:
140: public void setBufferSize(int arg0) {
141: throw new ImplementMe();
142:
143: }
144:
145: public void setCharacterEncoding(String arg0) {
146: throw new ImplementMe();
147:
148: }
149:
150: public void setContentLength(int arg0) {
151: throw new ImplementMe();
152:
153: }
154:
155: public void setContentType(String arg0) {
156: throw new ImplementMe();
157:
158: }
159:
160: public void setLocale(Locale arg0) {
161: throw new ImplementMe();
162:
163: }
164:
165: public Cookie[] getCookies() {
166: return (Cookie[]) cookies.toArray(new Cookie[cookies.size()]);
167: }
168:
169: }
|