Fri, 04 Oct 2013 16:21:34 +0100
8025054: Update JAX-WS RI integration to 2.2.9-b130926.1035
Reviewed-by: chegar
ohair@286 | 1 | /* |
mkos@397 | 2 | * Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved. |
ohair@286 | 3 | * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
ohair@286 | 4 | * |
ohair@286 | 5 | * This code is free software; you can redistribute it and/or modify it |
ohair@286 | 6 | * under the terms of the GNU General Public License version 2 only, as |
ohair@286 | 7 | * published by the Free Software Foundation. Oracle designates this |
ohair@286 | 8 | * particular file as subject to the "Classpath" exception as provided |
ohair@286 | 9 | * by Oracle in the LICENSE file that accompanied this code. |
ohair@286 | 10 | * |
ohair@286 | 11 | * This code is distributed in the hope that it will be useful, but WITHOUT |
ohair@286 | 12 | * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
ohair@286 | 13 | * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
ohair@286 | 14 | * version 2 for more details (a copy is included in the LICENSE file that |
ohair@286 | 15 | * accompanied this code). |
ohair@286 | 16 | * |
ohair@286 | 17 | * You should have received a copy of the GNU General Public License version |
ohair@286 | 18 | * 2 along with this work; if not, write to the Free Software Foundation, |
ohair@286 | 19 | * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
ohair@286 | 20 | * |
ohair@286 | 21 | * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
ohair@286 | 22 | * or visit www.oracle.com if you need additional information or have any |
ohair@286 | 23 | * questions. |
ohair@286 | 24 | */ |
ohair@286 | 25 | |
ohair@286 | 26 | package javax.xml.bind; |
ohair@286 | 27 | |
ohair@286 | 28 | /** |
ohair@286 | 29 | * <p> |
ohair@286 | 30 | * The DatatypeConverterInterface is for JAXB provider use only. A |
ohair@286 | 31 | * JAXB provider must supply a class that implements this interface. |
ohair@286 | 32 | * JAXB Providers are required to call the |
ohair@286 | 33 | * {@link DatatypeConverter#setDatatypeConverter(DatatypeConverterInterface) |
ohair@286 | 34 | * DatatypeConverter.setDatatypeConverter} api at |
ohair@286 | 35 | * some point before the first marshal or unmarshal operation (perhaps during |
ohair@286 | 36 | * the call to JAXBContext.newInstance). This step is necessary to configure |
ohair@286 | 37 | * the converter that should be used to perform the print and parse |
ohair@286 | 38 | * functionality. Calling this api repeatedly will have no effect - the |
ohair@286 | 39 | * DatatypeConverter instance passed into the first invocation is the one that |
ohair@286 | 40 | * will be used from then on. |
ohair@286 | 41 | * </p> |
ohair@286 | 42 | * |
ohair@286 | 43 | * <p> |
ohair@286 | 44 | * This interface defines the parse and print methods. There is one |
ohair@286 | 45 | * parse and print method for each XML schema datatype specified in the |
ohair@286 | 46 | * the default binding Table 5-1 in the JAXB specification. |
ohair@286 | 47 | * </p> |
ohair@286 | 48 | * |
ohair@286 | 49 | * <p> |
ohair@286 | 50 | * The parse and print methods defined here are invoked by the static parse |
ohair@286 | 51 | * and print methods defined in the {@link DatatypeConverter DatatypeConverter} |
ohair@286 | 52 | * class. |
ohair@286 | 53 | * </p> |
ohair@286 | 54 | * |
ohair@286 | 55 | * <p> |
ohair@286 | 56 | * A parse method for a XML schema datatype must be capable of converting any |
ohair@286 | 57 | * lexical representation of the XML schema datatype ( specified by the |
ohair@286 | 58 | * <a href="http://www.w3.org/TR/xmlschema-2/"> XML Schema Part2: Datatypes |
ohair@286 | 59 | * specification</a> into a value in the value space of the XML schema datatype. |
ohair@286 | 60 | * If an error is encountered during conversion, then an IllegalArgumentException |
ohair@286 | 61 | * or a subclass of IllegalArgumentException must be thrown by the method. |
ohair@286 | 62 | * |
ohair@286 | 63 | * </p> |
ohair@286 | 64 | * |
ohair@286 | 65 | * <p> |
ohair@286 | 66 | * A print method for a XML schema datatype can output any lexical |
ohair@286 | 67 | * representation that is valid with respect to the XML schema datatype. |
ohair@286 | 68 | * If an error is encountered during conversion, then an IllegalArgumentException, |
ohair@286 | 69 | * or a subclass of IllegalArgumentException must be thrown by the method. |
ohair@286 | 70 | * </p> |
ohair@286 | 71 | * |
ohair@286 | 72 | * The prefix xsd: is used to refer to XML schema datatypes |
ohair@286 | 73 | * <a href="http://www.w3.org/TR/xmlschema-2/"> XML Schema Part2: Datatypes |
ohair@286 | 74 | * specification.</a> |
ohair@286 | 75 | * |
ohair@286 | 76 | * <p> |
ohair@286 | 77 | * @author <ul><li>Sekhar Vajjhala, Sun Microsystems, Inc.</li><li>Joe Fialli, Sun Microsystems Inc.</li><li>Kohsuke Kawaguchi, Sun Microsystems, Inc.</li><li>Ryan Shoemaker,Sun Microsystems Inc.</li></ul> |
ohair@286 | 78 | * @see DatatypeConverter |
ohair@286 | 79 | * @see ParseConversionEvent |
ohair@286 | 80 | * @see PrintConversionEvent |
ohair@286 | 81 | * @since JAXB1.0 |
ohair@286 | 82 | */ |
ohair@286 | 83 | |
ohair@286 | 84 | public interface DatatypeConverterInterface { |
ohair@286 | 85 | /** |
ohair@286 | 86 | * <p> |
ohair@286 | 87 | * Convert the string argument into a string. |
ohair@286 | 88 | * @param lexicalXSDString |
ohair@286 | 89 | * A lexical representation of the XML Schema datatype xsd:string |
ohair@286 | 90 | * @return |
ohair@286 | 91 | * A string that is the same as the input string. |
ohair@286 | 92 | */ |
ohair@286 | 93 | public String parseString( String lexicalXSDString ); |
ohair@286 | 94 | |
ohair@286 | 95 | /** |
ohair@286 | 96 | * <p> |
ohair@286 | 97 | * Convert the string argument into a BigInteger value. |
ohair@286 | 98 | * @param lexicalXSDInteger |
ohair@286 | 99 | * A string containing a lexical representation of |
ohair@286 | 100 | * xsd:integer. |
ohair@286 | 101 | * @return |
ohair@286 | 102 | * A BigInteger value represented by the string argument. |
ohair@286 | 103 | * @throws NumberFormatException <code>lexicalXSDInteger</code> is not a valid string representation of a {@link java.math.BigInteger} value. |
ohair@286 | 104 | */ |
ohair@286 | 105 | public java.math.BigInteger parseInteger( String lexicalXSDInteger ); |
ohair@286 | 106 | |
ohair@286 | 107 | /** |
ohair@286 | 108 | * <p> |
ohair@286 | 109 | * Convert the string argument into an int value. |
ohair@286 | 110 | * @param lexicalXSDInt |
ohair@286 | 111 | * A string containing a lexical representation of |
ohair@286 | 112 | * xsd:int. |
ohair@286 | 113 | * @return |
ohair@286 | 114 | * An int value represented byte the string argument. |
ohair@286 | 115 | * @throws NumberFormatException <code>lexicalXSDInt</code> is not a valid string representation of an <code>int</code> value. |
ohair@286 | 116 | */ |
ohair@286 | 117 | public int parseInt( String lexicalXSDInt ); |
ohair@286 | 118 | |
ohair@286 | 119 | /** |
ohair@286 | 120 | * <p> |
ohair@286 | 121 | * Converts the string argument into a long value. |
ohair@286 | 122 | * @param lexicalXSDLong |
ohair@286 | 123 | * A string containing lexical representation of |
ohair@286 | 124 | * xsd:long. |
ohair@286 | 125 | * @return |
ohair@286 | 126 | * A long value represented by the string argument. |
ohair@286 | 127 | * @throws NumberFormatException <code>lexicalXSDLong</code> is not a valid string representation of a <code>long</code> value. |
ohair@286 | 128 | */ |
ohair@286 | 129 | public long parseLong( String lexicalXSDLong ); |
ohair@286 | 130 | |
ohair@286 | 131 | /** |
ohair@286 | 132 | * <p> |
ohair@286 | 133 | * Converts the string argument into a short value. |
ohair@286 | 134 | * @param lexicalXSDShort |
ohair@286 | 135 | * A string containing lexical representation of |
ohair@286 | 136 | * xsd:short. |
ohair@286 | 137 | * @return |
ohair@286 | 138 | * A short value represented by the string argument. |
ohair@286 | 139 | * @throws NumberFormatException <code>lexicalXSDShort</code> is not a valid string representation of a <code>short</code> value. |
ohair@286 | 140 | */ |
ohair@286 | 141 | public short parseShort( String lexicalXSDShort ); |
ohair@286 | 142 | |
ohair@286 | 143 | /** |
ohair@286 | 144 | * <p> |
ohair@286 | 145 | * Converts the string argument into a BigDecimal value. |
ohair@286 | 146 | * @param lexicalXSDDecimal |
ohair@286 | 147 | * A string containing lexical representation of |
ohair@286 | 148 | * xsd:decimal. |
ohair@286 | 149 | * @return |
ohair@286 | 150 | * A BigDecimal value represented by the string argument. |
ohair@286 | 151 | * @throws NumberFormatException <code>lexicalXSDDecimal</code> is not a valid string representation of {@link java.math.BigDecimal}. |
ohair@286 | 152 | */ |
ohair@286 | 153 | public java.math.BigDecimal parseDecimal( String lexicalXSDDecimal ); |
ohair@286 | 154 | |
ohair@286 | 155 | /** |
ohair@286 | 156 | * <p> |
ohair@286 | 157 | * Converts the string argument into a float value. |
ohair@286 | 158 | * @param lexicalXSDFloat |
ohair@286 | 159 | * A string containing lexical representation of |
ohair@286 | 160 | * xsd:float. |
ohair@286 | 161 | * @return |
ohair@286 | 162 | * A float value represented by the string argument. |
ohair@286 | 163 | * @throws NumberFormatException <code>lexicalXSDFloat</code> is not a valid string representation of a <code>float</code> value. |
ohair@286 | 164 | */ |
ohair@286 | 165 | public float parseFloat( String lexicalXSDFloat ); |
ohair@286 | 166 | |
ohair@286 | 167 | /** |
ohair@286 | 168 | * <p> |
ohair@286 | 169 | * Converts the string argument into a double value. |
ohair@286 | 170 | * @param lexicalXSDDouble |
ohair@286 | 171 | * A string containing lexical representation of |
ohair@286 | 172 | * xsd:double. |
ohair@286 | 173 | * @return |
ohair@286 | 174 | * A double value represented by the string argument. |
ohair@286 | 175 | * @throws NumberFormatException <code>lexicalXSDDouble</code> is not a valid string representation of a <code>double</code> value. |
ohair@286 | 176 | */ |
ohair@286 | 177 | public double parseDouble( String lexicalXSDDouble ); |
ohair@286 | 178 | |
ohair@286 | 179 | /** |
ohair@286 | 180 | * <p> |
ohair@286 | 181 | * Converts the string argument into a boolean value. |
ohair@286 | 182 | * @param lexicalXSDBoolean |
ohair@286 | 183 | * A string containing lexical representation of |
ohair@286 | 184 | * xsd:boolean. |
ohair@286 | 185 | * @return |
ohair@286 | 186 | * A boolean value represented by the string argument. |
ohair@286 | 187 | * @throws IllegalArgumentException if string parameter does not conform to lexical value space defined in XML Schema Part 2: Datatypes for xsd:boolean. |
ohair@286 | 188 | */ |
ohair@286 | 189 | public boolean parseBoolean( String lexicalXSDBoolean ); |
ohair@286 | 190 | |
ohair@286 | 191 | /** |
ohair@286 | 192 | * <p> |
ohair@286 | 193 | * Converts the string argument into a byte value. |
ohair@286 | 194 | * @param lexicalXSDByte |
ohair@286 | 195 | * A string containing lexical representation of |
ohair@286 | 196 | * xsd:byte. |
ohair@286 | 197 | * @return |
ohair@286 | 198 | * A byte value represented by the string argument. |
ohair@286 | 199 | * @throws NumberFormatException <code>lexicalXSDByte</code> does not contain a parseable byte. |
ohair@286 | 200 | * @throws IllegalArgumentException if string parameter does not conform to lexical value space defined in XML Schema Part 2: Datatypes for xsd:byte. |
ohair@286 | 201 | */ |
ohair@286 | 202 | public byte parseByte( String lexicalXSDByte ); |
ohair@286 | 203 | |
ohair@286 | 204 | /** |
ohair@286 | 205 | * <p> |
ohair@286 | 206 | * Converts the string argument into a QName value. |
ohair@286 | 207 | * |
ohair@286 | 208 | * <p> |
ohair@286 | 209 | * String parameter <tt>lexicalXSDQname</tt> must conform to lexical value space specifed at |
ohair@286 | 210 | * <a href="http://www.w3.org/TR/xmlschema-2/#QName">XML Schema Part 2:Datatypes specification:QNames</a> |
ohair@286 | 211 | * |
ohair@286 | 212 | * @param lexicalXSDQName |
ohair@286 | 213 | * A string containing lexical representation of xsd:QName. |
ohair@286 | 214 | * @param nsc |
ohair@286 | 215 | * A namespace context for interpreting a prefix within a QName. |
ohair@286 | 216 | * @return |
ohair@286 | 217 | * A QName value represented by the string argument. |
ohair@286 | 218 | * @throws IllegalArgumentException if string parameter does not conform to XML Schema Part 2 specification or |
ohair@286 | 219 | * if namespace prefix of <tt>lexicalXSDQname</tt> is not bound to a URI in NamespaceContext <tt>nsc</tt>. |
ohair@286 | 220 | */ |
ohair@286 | 221 | public javax.xml.namespace.QName parseQName( String lexicalXSDQName, |
ohair@286 | 222 | javax.xml.namespace.NamespaceContext nsc); |
ohair@286 | 223 | |
ohair@286 | 224 | /** |
ohair@286 | 225 | * <p> |
ohair@286 | 226 | * Converts the string argument into a Calendar value. |
ohair@286 | 227 | * @param lexicalXSDDateTime |
ohair@286 | 228 | * A string containing lexical representation of |
ohair@286 | 229 | * xsd:datetime. |
ohair@286 | 230 | * @return |
ohair@286 | 231 | * A Calendar object represented by the string argument. |
ohair@286 | 232 | * @throws IllegalArgumentException if string parameter does not conform to lexical value space defined in XML Schema Part 2: Datatypes for xsd:dateTime. |
ohair@286 | 233 | */ |
ohair@286 | 234 | public java.util.Calendar parseDateTime( String lexicalXSDDateTime ); |
ohair@286 | 235 | |
ohair@286 | 236 | /** |
ohair@286 | 237 | * <p> |
ohair@286 | 238 | * Converts the string argument into an array of bytes. |
ohair@286 | 239 | * @param lexicalXSDBase64Binary |
ohair@286 | 240 | * A string containing lexical representation |
ohair@286 | 241 | * of xsd:base64Binary. |
ohair@286 | 242 | * @return |
ohair@286 | 243 | * An array of bytes represented by the string argument. |
ohair@286 | 244 | * @throws IllegalArgumentException if string parameter does not conform to lexical value space defined in XML Schema Part 2: Datatypes for xsd:base64Binary |
ohair@286 | 245 | */ |
ohair@286 | 246 | public byte[] parseBase64Binary( String lexicalXSDBase64Binary ); |
ohair@286 | 247 | |
ohair@286 | 248 | /** |
ohair@286 | 249 | * <p> |
ohair@286 | 250 | * Converts the string argument into an array of bytes. |
ohair@286 | 251 | * @param lexicalXSDHexBinary |
ohair@286 | 252 | * A string containing lexical representation of |
ohair@286 | 253 | * xsd:hexBinary. |
ohair@286 | 254 | * @return |
ohair@286 | 255 | * An array of bytes represented by the string argument. |
ohair@286 | 256 | * @throws IllegalArgumentException if string parameter does not conform to lexical value space defined in XML Schema Part 2: Datatypes for xsd:hexBinary. |
ohair@286 | 257 | */ |
ohair@286 | 258 | public byte[] parseHexBinary( String lexicalXSDHexBinary ); |
ohair@286 | 259 | |
ohair@286 | 260 | /** |
ohair@286 | 261 | * <p> |
ohair@286 | 262 | * Converts the string argument into a long value. |
ohair@286 | 263 | * @param lexicalXSDUnsignedInt |
ohair@286 | 264 | * A string containing lexical representation |
ohair@286 | 265 | * of xsd:unsignedInt. |
ohair@286 | 266 | * @return |
ohair@286 | 267 | * A long value represented by the string argument. |
ohair@286 | 268 | * @throws NumberFormatException if string parameter can not be parsed into a <tt>long</tt> value. |
ohair@286 | 269 | */ |
ohair@286 | 270 | public long parseUnsignedInt( String lexicalXSDUnsignedInt ); |
ohair@286 | 271 | |
ohair@286 | 272 | /** |
ohair@286 | 273 | * <p> |
ohair@286 | 274 | * Converts the string argument into an int value. |
ohair@286 | 275 | * @param lexicalXSDUnsignedShort |
ohair@286 | 276 | * A string containing lexical |
ohair@286 | 277 | * representation of xsd:unsignedShort. |
ohair@286 | 278 | * @return |
ohair@286 | 279 | * An int value represented by the string argument. |
ohair@286 | 280 | * @throws NumberFormatException if string parameter can not be parsed into an <tt>int</tt> value. |
ohair@286 | 281 | */ |
ohair@286 | 282 | public int parseUnsignedShort( String lexicalXSDUnsignedShort ); |
ohair@286 | 283 | |
ohair@286 | 284 | /** |
ohair@286 | 285 | * <p> |
ohair@286 | 286 | * Converts the string argument into a Calendar value. |
ohair@286 | 287 | * @param lexicalXSDTime |
ohair@286 | 288 | * A string containing lexical representation of |
ohair@286 | 289 | * xsd:Time. |
ohair@286 | 290 | * @return |
ohair@286 | 291 | * A Calendar value represented by the string argument. |
ohair@286 | 292 | * @throws IllegalArgumentException if string parameter does not conform to lexical value space defined in XML Schema Part 2: Datatypes for xsd:Time. |
ohair@286 | 293 | */ |
ohair@286 | 294 | public java.util.Calendar parseTime( String lexicalXSDTime ); |
ohair@286 | 295 | |
ohair@286 | 296 | /** |
ohair@286 | 297 | * <p> |
ohair@286 | 298 | * Converts the string argument into a Calendar value. |
ohair@286 | 299 | * @param lexicalXSDDate |
ohair@286 | 300 | * A string containing lexical representation of |
ohair@286 | 301 | * xsd:Date. |
ohair@286 | 302 | * @return |
ohair@286 | 303 | * A Calendar value represented by the string argument. |
ohair@286 | 304 | * @throws IllegalArgumentException if string parameter does not conform to lexical value space defined in XML Schema Part 2: Datatypes for xsd:Date. |
ohair@286 | 305 | */ |
ohair@286 | 306 | public java.util.Calendar parseDate( String lexicalXSDDate ); |
ohair@286 | 307 | |
ohair@286 | 308 | /** |
ohair@286 | 309 | * <p> |
ohair@286 | 310 | * Return a string containing the lexical representation of the |
ohair@286 | 311 | * simple type. |
ohair@286 | 312 | * @param lexicalXSDAnySimpleType |
ohair@286 | 313 | * A string containing lexical |
ohair@286 | 314 | * representation of the simple type. |
ohair@286 | 315 | * @return |
ohair@286 | 316 | * A string containing the lexical representation of the |
ohair@286 | 317 | * simple type. |
ohair@286 | 318 | */ |
ohair@286 | 319 | public String parseAnySimpleType( String lexicalXSDAnySimpleType ); |
ohair@286 | 320 | |
ohair@286 | 321 | /** |
ohair@286 | 322 | * <p> |
ohair@286 | 323 | * Converts the string argument into a string. |
ohair@286 | 324 | * @param val |
ohair@286 | 325 | * A string value. |
ohair@286 | 326 | * @return |
ohair@286 | 327 | * A string containing a lexical representation of xsd:string |
ohair@286 | 328 | */ |
ohair@286 | 329 | public String printString( String val ); |
ohair@286 | 330 | |
ohair@286 | 331 | /** |
ohair@286 | 332 | * <p> |
ohair@286 | 333 | * Converts a BigInteger value into a string. |
ohair@286 | 334 | * @param val |
ohair@286 | 335 | * A BigInteger value |
ohair@286 | 336 | * @return |
ohair@286 | 337 | * A string containing a lexical representation of xsd:integer |
ohair@286 | 338 | * @throws IllegalArgumentException <tt>val</tt> is null. |
ohair@286 | 339 | */ |
ohair@286 | 340 | public String printInteger( java.math.BigInteger val ); |
ohair@286 | 341 | |
ohair@286 | 342 | /** |
ohair@286 | 343 | * <p> |
ohair@286 | 344 | * Converts an int value into a string. |
ohair@286 | 345 | * @param val |
ohair@286 | 346 | * An int value |
ohair@286 | 347 | * @return |
ohair@286 | 348 | * A string containing a lexical representation of xsd:int |
ohair@286 | 349 | */ |
ohair@286 | 350 | public String printInt( int val ); |
ohair@286 | 351 | |
ohair@286 | 352 | |
ohair@286 | 353 | /** |
ohair@286 | 354 | * <p> |
ohair@286 | 355 | * Converts a long value into a string. |
ohair@286 | 356 | * @param val |
ohair@286 | 357 | * A long value |
ohair@286 | 358 | * @return |
ohair@286 | 359 | * A string containing a lexical representation of xsd:long |
ohair@286 | 360 | */ |
ohair@286 | 361 | public String printLong( long val ); |
ohair@286 | 362 | |
ohair@286 | 363 | /** |
ohair@286 | 364 | * <p> |
ohair@286 | 365 | * Converts a short value into a string. |
ohair@286 | 366 | * @param val |
ohair@286 | 367 | * A short value |
ohair@286 | 368 | * @return |
ohair@286 | 369 | * A string containing a lexical representation of xsd:short |
ohair@286 | 370 | */ |
ohair@286 | 371 | public String printShort( short val ); |
ohair@286 | 372 | |
ohair@286 | 373 | /** |
ohair@286 | 374 | * <p> |
ohair@286 | 375 | * Converts a BigDecimal value into a string. |
ohair@286 | 376 | * @param val |
ohair@286 | 377 | * A BigDecimal value |
ohair@286 | 378 | * @return |
ohair@286 | 379 | * A string containing a lexical representation of xsd:decimal |
ohair@286 | 380 | * @throws IllegalArgumentException <tt>val</tt> is null. |
ohair@286 | 381 | */ |
ohair@286 | 382 | public String printDecimal( java.math.BigDecimal val ); |
ohair@286 | 383 | |
ohair@286 | 384 | /** |
ohair@286 | 385 | * <p> |
ohair@286 | 386 | * Converts a float value into a string. |
ohair@286 | 387 | * @param val |
ohair@286 | 388 | * A float value |
ohair@286 | 389 | * @return |
ohair@286 | 390 | * A string containing a lexical representation of xsd:float |
ohair@286 | 391 | */ |
ohair@286 | 392 | public String printFloat( float val ); |
ohair@286 | 393 | |
ohair@286 | 394 | /** |
ohair@286 | 395 | * <p> |
ohair@286 | 396 | * Converts a double value into a string. |
ohair@286 | 397 | * @param val |
ohair@286 | 398 | * A double value |
ohair@286 | 399 | * @return |
ohair@286 | 400 | * A string containing a lexical representation of xsd:double |
ohair@286 | 401 | */ |
ohair@286 | 402 | public String printDouble( double val ); |
ohair@286 | 403 | |
ohair@286 | 404 | /** |
ohair@286 | 405 | * <p> |
ohair@286 | 406 | * Converts a boolean value into a string. |
ohair@286 | 407 | * @param val |
ohair@286 | 408 | * A boolean value |
ohair@286 | 409 | * @return |
ohair@286 | 410 | * A string containing a lexical representation of xsd:boolean |
ohair@286 | 411 | */ |
ohair@286 | 412 | public String printBoolean( boolean val ); |
ohair@286 | 413 | |
ohair@286 | 414 | /** |
ohair@286 | 415 | * <p> |
ohair@286 | 416 | * Converts a byte value into a string. |
ohair@286 | 417 | * @param val |
ohair@286 | 418 | * A byte value |
ohair@286 | 419 | * @return |
ohair@286 | 420 | * A string containing a lexical representation of xsd:byte |
ohair@286 | 421 | */ |
ohair@286 | 422 | public String printByte( byte val ); |
ohair@286 | 423 | |
ohair@286 | 424 | /** |
ohair@286 | 425 | * <p> |
ohair@286 | 426 | * Converts a QName instance into a string. |
ohair@286 | 427 | * @param val |
ohair@286 | 428 | * A QName value |
ohair@286 | 429 | * @param nsc |
ohair@286 | 430 | * A namespace context for interpreting a prefix within a QName. |
ohair@286 | 431 | * @return |
ohair@286 | 432 | * A string containing a lexical representation of QName |
ohair@286 | 433 | * @throws IllegalArgumentException if <tt>val</tt> is null or |
ohair@286 | 434 | * if <tt>nsc</tt> is non-null or <tt>nsc.getPrefix(nsprefixFromVal)</tt> is null. |
ohair@286 | 435 | */ |
ohair@286 | 436 | public String printQName( javax.xml.namespace.QName val, |
ohair@286 | 437 | javax.xml.namespace.NamespaceContext nsc ); |
ohair@286 | 438 | |
ohair@286 | 439 | /** |
ohair@286 | 440 | * <p> |
ohair@286 | 441 | * Converts a Calendar value into a string. |
ohair@286 | 442 | * @param val |
ohair@286 | 443 | * A Calendar value |
ohair@286 | 444 | * @return |
ohair@286 | 445 | * A string containing a lexical representation of xsd:dateTime |
ohair@286 | 446 | * @throws IllegalArgumentException if <tt>val</tt> is null. |
ohair@286 | 447 | */ |
ohair@286 | 448 | public String printDateTime( java.util.Calendar val ); |
ohair@286 | 449 | |
ohair@286 | 450 | /** |
ohair@286 | 451 | * <p> |
ohair@286 | 452 | * Converts an array of bytes into a string. |
ohair@286 | 453 | * @param val |
ohair@286 | 454 | * an array of bytes |
ohair@286 | 455 | * @return |
ohair@286 | 456 | * A string containing a lexical representation of xsd:base64Binary |
ohair@286 | 457 | * @throws IllegalArgumentException if <tt>val</tt> is null. |
ohair@286 | 458 | */ |
ohair@286 | 459 | public String printBase64Binary( byte[] val ); |
ohair@286 | 460 | |
ohair@286 | 461 | /** |
ohair@286 | 462 | * <p> |
ohair@286 | 463 | * Converts an array of bytes into a string. |
ohair@286 | 464 | * @param val |
ohair@286 | 465 | * an array of bytes |
ohair@286 | 466 | * @return |
ohair@286 | 467 | * A string containing a lexical representation of xsd:hexBinary |
ohair@286 | 468 | * @throws IllegalArgumentException if <tt>val</tt> is null. |
ohair@286 | 469 | */ |
ohair@286 | 470 | public String printHexBinary( byte[] val ); |
ohair@286 | 471 | |
ohair@286 | 472 | /** |
ohair@286 | 473 | * <p> |
ohair@286 | 474 | * Converts a long value into a string. |
ohair@286 | 475 | * @param val |
ohair@286 | 476 | * A long value |
ohair@286 | 477 | * @return |
ohair@286 | 478 | * A string containing a lexical representation of xsd:unsignedInt |
ohair@286 | 479 | */ |
ohair@286 | 480 | public String printUnsignedInt( long val ); |
ohair@286 | 481 | |
ohair@286 | 482 | /** |
ohair@286 | 483 | * <p> |
ohair@286 | 484 | * Converts an int value into a string. |
ohair@286 | 485 | * @param val |
ohair@286 | 486 | * An int value |
ohair@286 | 487 | * @return |
ohair@286 | 488 | * A string containing a lexical representation of xsd:unsignedShort |
ohair@286 | 489 | */ |
ohair@286 | 490 | public String printUnsignedShort( int val ); |
ohair@286 | 491 | |
ohair@286 | 492 | /** |
ohair@286 | 493 | * <p> |
ohair@286 | 494 | * Converts a Calendar value into a string. |
ohair@286 | 495 | * @param val |
ohair@286 | 496 | * A Calendar value |
ohair@286 | 497 | * @return |
ohair@286 | 498 | * A string containing a lexical representation of xsd:time |
ohair@286 | 499 | * @throws IllegalArgumentException if <tt>val</tt> is null. |
ohair@286 | 500 | */ |
ohair@286 | 501 | public String printTime( java.util.Calendar val ); |
ohair@286 | 502 | |
ohair@286 | 503 | /** |
ohair@286 | 504 | * <p> |
ohair@286 | 505 | * Converts a Calendar value into a string. |
ohair@286 | 506 | * @param val |
ohair@286 | 507 | * A Calendar value |
ohair@286 | 508 | * @return |
ohair@286 | 509 | * A string containing a lexical representation of xsd:date |
ohair@286 | 510 | * @throws IllegalArgumentException if <tt>val</tt> is null. |
ohair@286 | 511 | */ |
ohair@286 | 512 | public String printDate( java.util.Calendar val ); |
ohair@286 | 513 | |
ohair@286 | 514 | /** |
ohair@286 | 515 | * <p> |
ohair@286 | 516 | * Converts a string value into a string. |
ohair@286 | 517 | * @param val |
ohair@286 | 518 | * A string value |
ohair@286 | 519 | * @return |
ohair@286 | 520 | * A string containing a lexical representation of xsd:AnySimpleType |
ohair@286 | 521 | */ |
ohair@286 | 522 | public String printAnySimpleType( String val ); |
ohair@286 | 523 | } |