Wed, 27 Apr 2016 01:27:09 +0800
Initial load
http://hg.openjdk.java.net/jdk8u/jdk8u/jaxws/
changeset: 657:d47a47f961ee
tag: jdk8u25-b17
1 /*
2 * Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * This code is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License version 2 only, as
7 * published by the Free Software Foundation. Oracle designates this
8 * particular file as subject to the "Classpath" exception as provided
9 * by Oracle in the LICENSE file that accompanied this code.
10 *
11 * This code is distributed in the hope that it will be useful, but WITHOUT
12 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
14 * version 2 for more details (a copy is included in the LICENSE file that
15 * accompanied this code).
16 *
17 * You should have received a copy of the GNU General Public License version
18 * 2 along with this work; if not, write to the Free Software Foundation,
19 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
20 *
21 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
22 * or visit www.oracle.com if you need additional information or have any
23 * questions.
24 *
25 * THIS FILE WAS MODIFIED BY SUN MICROSYSTEMS, INC.
26 */
28 package com.sun.xml.internal.fastinfoset.stax.util;
30 import javax.xml.namespace.QName;
31 import javax.xml.namespace.NamespaceContext;
33 import javax.xml.stream.XMLStreamReader;
34 import javax.xml.stream.Location;
35 import javax.xml.stream.XMLStreamException;
38 public class StAXParserWrapper implements XMLStreamReader{
39 private XMLStreamReader _reader;
41 /** Creates a new instance of StAXParserWrapper */
42 public StAXParserWrapper() {
43 }
45 public StAXParserWrapper(XMLStreamReader reader) {
46 _reader = reader;
47 }
48 public void setReader(XMLStreamReader reader) {
49 _reader = reader;
50 }
51 public XMLStreamReader getReader() {
52 return _reader;
53 }
55 public int next() throws XMLStreamException
56 {
57 return _reader.next();
58 }
60 public int nextTag() throws XMLStreamException
61 {
62 return _reader.nextTag();
63 }
65 public String getElementText() throws XMLStreamException
66 {
67 return _reader.getElementText();
68 }
70 public void require(int type, String namespaceURI, String localName) throws XMLStreamException
71 {
72 _reader.require(type,namespaceURI,localName);
73 }
75 public boolean hasNext() throws XMLStreamException
76 {
77 return _reader.hasNext();
78 }
80 public void close() throws XMLStreamException
81 {
82 _reader.close();
83 }
85 public String getNamespaceURI(String prefix)
86 {
87 return _reader.getNamespaceURI(prefix);
88 }
90 public NamespaceContext getNamespaceContext() {
91 return _reader.getNamespaceContext();
92 }
94 public boolean isStartElement() {
95 return _reader.isStartElement();
96 }
98 public boolean isEndElement() {
99 return _reader.isEndElement();
100 }
102 public boolean isCharacters() {
103 return _reader.isCharacters();
104 }
106 public boolean isWhiteSpace() {
107 return _reader.isWhiteSpace();
108 }
110 public QName getAttributeName(int index) {
111 return _reader.getAttributeName(index);
112 }
114 public int getTextCharacters(int sourceStart, char[] target, int targetStart,
115 int length) throws XMLStreamException
116 {
117 return _reader.getTextCharacters(sourceStart, target, targetStart, length);
118 }
120 public String getAttributeValue(String namespaceUri,
121 String localName)
122 {
123 return _reader.getAttributeValue(namespaceUri,localName);
124 }
125 public int getAttributeCount() {
126 return _reader.getAttributeCount();
127 }
128 public String getAttributePrefix(int index) {
129 return _reader.getAttributePrefix(index);
130 }
131 public String getAttributeNamespace(int index) {
132 return _reader.getAttributeNamespace(index);
133 }
134 public String getAttributeLocalName(int index) {
135 return _reader.getAttributeLocalName(index);
136 }
137 public String getAttributeType(int index) {
138 return _reader.getAttributeType(index);
139 }
140 public String getAttributeValue(int index) {
141 return _reader.getAttributeValue(index);
142 }
143 public boolean isAttributeSpecified(int index) {
144 return _reader.isAttributeSpecified(index);
145 }
147 public int getNamespaceCount() {
148 return _reader.getNamespaceCount();
149 }
150 public String getNamespacePrefix(int index) {
151 return _reader.getNamespacePrefix(index);
152 }
153 public String getNamespaceURI(int index) {
154 return _reader.getNamespaceURI(index);
155 }
157 public int getEventType() {
158 return _reader.getEventType();
159 }
161 public String getText() {
162 return _reader.getText();
163 }
165 public char[] getTextCharacters() {
166 return _reader.getTextCharacters();
167 }
169 public int getTextStart() {
170 return _reader.getTextStart();
171 }
173 public int getTextLength() {
174 return _reader.getTextLength();
175 }
177 public String getEncoding() {
178 return _reader.getEncoding();
179 }
181 public boolean hasText() {
182 return _reader.hasText();
183 }
185 public Location getLocation() {
186 return _reader.getLocation();
187 }
189 public QName getName() {
190 return _reader.getName();
191 }
193 public String getLocalName() {
194 return _reader.getLocalName();
195 }
197 public boolean hasName() {
198 return _reader.hasName();
199 }
201 public String getNamespaceURI() {
202 return _reader.getNamespaceURI();
203 }
205 public String getPrefix() {
206 return _reader.getPrefix();
207 }
209 public String getVersion() {
210 return _reader.getVersion();
211 }
213 public boolean isStandalone() {
214 return _reader.isStandalone();
215 }
217 public boolean standaloneSet() {
218 return _reader.standaloneSet();
219 }
221 public String getCharacterEncodingScheme() {
222 return _reader.getCharacterEncodingScheme();
223 }
225 public String getPITarget() {
226 return _reader.getPITarget();
227 }
229 public String getPIData() {
230 return _reader.getPIData();
231 }
233 public Object getProperty(String name) {
234 return _reader.getProperty(name);
235 }
236 }