KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > jboss > webservice > encoding > ser > SOAPArraySerializer


1 /**
2  * JBoss, the OpenSource J2EE webOS
3  *
4  * Distributable under LGPL license.
5  * See terms of license at gnu.org.
6  */

7 package org.jboss.webservice.encoding.ser;
8
9 // $Id: SOAPArraySerializer.java,v 1.1.4.1 2005/03/02 14:32:30 tdiesler Exp $
10

11 import org.jboss.axis.Constants;
12 import org.jboss.axis.encoding.ser.ArraySerializer;
13
14 import javax.xml.namespace.QName JavaDoc;
15 import java.math.BigDecimal JavaDoc;
16
17 /**
18  * DOCUMENT ME!
19  *
20  * @author thomas.diesler@jboss.org
21  */

22 public class SOAPArraySerializer extends ArraySerializer
23 {
24    public SOAPArraySerializer(Class JavaDoc javaType, QName JavaDoc xmlType)
25    {
26       addComponentTypeMapping(String JavaDoc.class, new QName JavaDoc(Constants.URI_SOAP11_ENC, "string"));
27       addComponentTypeMapping(Boolean JavaDoc.class, new QName JavaDoc(Constants.URI_SOAP11_ENC, "boolean"));
28       addComponentTypeMapping(Float JavaDoc.class, new QName JavaDoc(Constants.URI_SOAP11_ENC, "float"));
29       addComponentTypeMapping(Double JavaDoc.class, new QName JavaDoc(Constants.URI_SOAP11_ENC, "double"));
30       addComponentTypeMapping(BigDecimal JavaDoc.class, new QName JavaDoc(Constants.URI_SOAP11_ENC, "decimal"));
31       addComponentTypeMapping(Integer JavaDoc.class, new QName JavaDoc(Constants.URI_SOAP11_ENC, "int"));
32       addComponentTypeMapping(Short JavaDoc.class, new QName JavaDoc(Constants.URI_SOAP11_ENC, "short"));
33       addComponentTypeMapping(Byte JavaDoc.class, new QName JavaDoc(Constants.URI_SOAP11_ENC, "byte"));
34       addComponentTypeMapping(byte[].class, new QName JavaDoc(Constants.URI_SOAP11_ENC, "base64"));
35    }
36 }
37
Popular Tags