001: /*
002: * Licensed to the Apache Software Foundation (ASF) under one
003: * or more contributor license agreements. See the NOTICE file
004: * distributed with this work for additional information
005: * regarding copyright ownership. The ASF licenses this file
006: * to you under the Apache License, Version 2.0 (the
007: * "License"); you may not use this file except in compliance
008: * with the License. You may obtain a copy of the License at
009: *
010: * http://www.apache.org/licenses/LICENSE-2.0
011: *
012: * Unless required by applicable law or agreed to in writing,
013: * software distributed under the License is distributed on an
014: * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
015: * KIND, either express or implied. See the License for the
016: * specific language governing permissions and limitations
017: * under the License.
018: */
019: package org.apache.axis2.jaxws.message.util;
020:
021: import javax.xml.namespace.NamespaceContext;
022: import javax.xml.namespace.QName;
023: import javax.xml.stream.Location;
024: import javax.xml.stream.XMLStreamException;
025: import javax.xml.stream.XMLStreamReader;
026:
027: /**
028: * XMLStreamReaderFilter Abstract class that simply delegates to the initial reader. This class is
029: * useful for building filters
030: */
031: public abstract class XMLStreamReaderFilter implements XMLStreamReader {
032:
033: protected XMLStreamReader delegate;
034:
035: /**
036: * Construct a Filter
037: *
038: * @param reader XMLStreamReader that is filtered.
039: */
040: public XMLStreamReaderFilter(XMLStreamReader reader) {
041: delegate = reader;
042: }
043:
044: public void close() throws XMLStreamException {
045: delegate.close();
046: }
047:
048: public int getAttributeCount() {
049: return delegate.getAttributeCount();
050: }
051:
052: public String getAttributeLocalName(int arg0) {
053: return delegate.getAttributeLocalName(arg0);
054: }
055:
056: public QName getAttributeName(int arg0) {
057: return delegate.getAttributeName(arg0);
058: }
059:
060: public String getAttributeNamespace(int arg0) {
061: return delegate.getAttributeNamespace(arg0);
062: }
063:
064: public String getAttributePrefix(int arg0) {
065: return delegate.getAttributePrefix(arg0);
066: }
067:
068: public String getAttributeType(int arg0) {
069: return delegate.getAttributeType(arg0);
070: }
071:
072: public String getAttributeValue(int arg0) {
073: return delegate.getAttributeValue(arg0);
074: }
075:
076: public String getAttributeValue(String arg0, String arg1) {
077: return delegate.getAttributeValue(arg0, arg1);
078: }
079:
080: public String getCharacterEncodingScheme() {
081: return delegate.getCharacterEncodingScheme();
082: }
083:
084: public String getElementText() throws XMLStreamException {
085: return delegate.getElementText();
086: }
087:
088: public String getEncoding() {
089: return delegate.getEncoding();
090: }
091:
092: public int getEventType() {
093: return delegate.getEventType();
094: }
095:
096: public String getLocalName() {
097: return delegate.getLocalName();
098: }
099:
100: public Location getLocation() {
101: return delegate.getLocation();
102: }
103:
104: public QName getName() {
105: return delegate.getName();
106: }
107:
108: public NamespaceContext getNamespaceContext() {
109: return delegate.getNamespaceContext();
110: }
111:
112: public int getNamespaceCount() {
113: return delegate.getNamespaceCount();
114: }
115:
116: public String getNamespacePrefix(int arg0) {
117: return delegate.getNamespacePrefix(arg0);
118: }
119:
120: public String getNamespaceURI() {
121: return delegate.getNamespaceURI();
122: }
123:
124: public String getNamespaceURI(int arg0) {
125: return delegate.getNamespaceURI(arg0);
126: }
127:
128: public String getNamespaceURI(String arg0) {
129: return delegate.getNamespaceURI(arg0);
130: }
131:
132: public String getPIData() {
133: return delegate.getPIData();
134: }
135:
136: public String getPITarget() {
137: return delegate.getPITarget();
138: }
139:
140: public String getPrefix() {
141: return delegate.getPrefix();
142: }
143:
144: public Object getProperty(String arg0)
145: throws IllegalArgumentException {
146: return delegate.getProperty(arg0);
147: }
148:
149: public String getText() {
150: return delegate.getText();
151: }
152:
153: public char[] getTextCharacters() {
154: return delegate.getTextCharacters();
155: }
156:
157: public int getTextCharacters(int arg0, char[] arg1, int arg2,
158: int arg3) throws XMLStreamException {
159: return delegate.getTextCharacters(arg0, arg1, arg2, arg3);
160: }
161:
162: public int getTextLength() {
163: return delegate.getTextLength();
164: }
165:
166: public int getTextStart() {
167: return delegate.getTextStart();
168: }
169:
170: public String getVersion() {
171: return delegate.getVersion();
172: }
173:
174: public boolean hasName() {
175: return delegate.hasName();
176: }
177:
178: public boolean hasNext() throws XMLStreamException {
179: return delegate.hasNext();
180: }
181:
182: public boolean hasText() {
183: return delegate.hasText();
184: }
185:
186: public boolean isAttributeSpecified(int arg0) {
187: return delegate.isAttributeSpecified(arg0);
188: }
189:
190: public boolean isCharacters() {
191: return delegate.isCharacters();
192: }
193:
194: public boolean isEndElement() {
195: return delegate.isEndElement();
196: }
197:
198: public boolean isStandalone() {
199: return delegate.isStandalone();
200: }
201:
202: public boolean isStartElement() {
203: return delegate.isStartElement();
204: }
205:
206: public boolean isWhiteSpace() {
207: return delegate.isWhiteSpace();
208: }
209:
210: public int next() throws XMLStreamException {
211: return delegate.next();
212: }
213:
214: public int nextTag() throws XMLStreamException {
215: return delegate.nextTag();
216: }
217:
218: public void require(int arg0, String arg1, String arg2)
219: throws XMLStreamException {
220: delegate.require(arg0, arg1, arg2);
221: }
222:
223: public boolean standaloneSet() {
224: return delegate.standaloneSet();
225: }
226:
227: }
|