001: /*
002: * Copyright 2006 The Apache Software Foundation.
003: *
004: * Licensed under the Apache License, Version 2.0 (the "License");
005: * you may not use this file except in compliance with the License.
006: * You may obtain a copy of the License at
007: *
008: * http://www.apache.org/licenses/LICENSE-2.0
009: *
010: * Unless required by applicable law or agreed to in writing, software
011: * distributed under the License is distributed on an "AS IS" BASIS,
012: * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
013: * See the License for the specific language governing permissions and
014: * limitations under the License.
015: */
016:
017: package javax.faces.context;
018:
019: import javax.faces.component.UIComponent;
020: import java.io.IOException;
021: import java.io.Writer;
022:
023: /**
024: * see Javadoc of <a href="http://java.sun.com/j2ee/javaserverfaces/1.2/docs/api/index.html">JSF Specification</a>
025: *
026: * @author Stan Silvert
027: */
028: public abstract class ResponseWriterWrapper extends ResponseWriter {
029:
030: protected abstract ResponseWriter getWrapped();
031:
032: public void endElement(String name) throws IOException {
033: getWrapped().endElement(name);
034: }
035:
036: public void writeComment(Object comment) throws IOException {
037: getWrapped().writeComment(comment);
038: }
039:
040: public void startElement(String name, UIComponent component)
041: throws IOException {
042: getWrapped().startElement(name, component);
043: }
044:
045: public void writeText(Object text, String property)
046: throws IOException {
047: getWrapped().writeText(text, property);
048: }
049:
050: public void writeText(char[] text, int off, int len)
051: throws IOException {
052: getWrapped().writeText(text, off, len);
053: }
054:
055: public void write(char[] cbuf, int off, int len) throws IOException {
056: getWrapped().write(cbuf, off, len);
057: }
058:
059: public ResponseWriter cloneWithWriter(Writer writer) {
060: return getWrapped().cloneWithWriter(writer);
061: }
062:
063: public void writeURIAttribute(String name, Object value,
064: String property) throws IOException {
065: getWrapped().writeURIAttribute(name, value, property);
066: }
067:
068: public void close() throws IOException {
069: getWrapped().close();
070: }
071:
072: public void endDocument() throws IOException {
073: getWrapped().endDocument();
074: }
075:
076: public void flush() throws IOException {
077: getWrapped().flush();
078: }
079:
080: public String getCharacterEncoding() {
081: return getWrapped().getCharacterEncoding();
082: }
083:
084: public String getContentType() {
085: return getWrapped().getContentType();
086: }
087:
088: public void startDocument() throws IOException {
089: getWrapped().startDocument();
090: }
091:
092: public void writeAttribute(String name, Object value,
093: String property) throws IOException {
094: getWrapped().writeAttribute(name, value, property);
095: }
096:
097: /**
098: * @since 1.2
099: */
100: public void writeText(Object object, UIComponent component,
101: String string) throws IOException {
102: getWrapped().writeText(object, component, string);
103: }
104:
105: }
|