Package org.apache.axis.encoding

Examples of org.apache.axis.encoding.SerializerFactory


            }
            TypeMapping tm = tmr.getOrMakeTypeMapping(encodingStyle);
            desc.setTypeMappingRegistry(tmr);
            desc.setTypeMapping(tm);

            SerializerFactory   ser   = null;
            DeserializerFactory deser = null;

            // Try to construct a serializerFactory by introspecting for the
            // following:
            // public static create(Class javaType, QName xmlType)
View Full Code Here


                                    QName xmlType,
                                    Class sfClass,
                                    Class dfClass,
                                    boolean force) {
        // Instantiate the factory using introspection.
        SerializerFactory   sf =
                BaseSerializerFactory.createFactory(sfClass, javaType, xmlType);
        DeserializerFactory df =
                BaseDeserializerFactory.createFactory(dfClass,
                                                      javaType,
                                                      xmlType);
View Full Code Here

            return true;
        }

        // look up the serializer in the TypeMappingRegistry
        Serializer ser = null;
        SerializerFactory factory = null;

        if (tm != null) {
            factory = (SerializerFactory) tm.getSerializer(type);
        } else {
            factory = (SerializerFactory) defaultTM.getSerializer(type);
        }

        // If no factory is found, use the BeanSerializerFactory
        // if applicable, otherwise issue errors and treat as an anyType
        if (factory == null) {
            if (isEnumClass(type)) {
                factory = new EnumSerializerFactory(type, qName);
            } else if (isBeanCompatible(type, true)) {
                factory = new BeanSerializerFactory(type, qName);
            } else {
                return false;
            }
        }

        if (factory != null) {
            ser = (Serializer) factory.getSerializerAs(Constants.AXIS_SAX);
        }

        // if we can't get a serializer, that is bad.
        if (ser == null) {
            throw new AxisFault(Messages.getMessage("NoSerializer00",
View Full Code Here

            if (encodingStyle == null) {
                encodingStyle = Constants.URI_DEFAULT_SOAP_ENC;
            }
            TypeMapping tm = tmr.getOrMakeTypeMapping(encodingStyle);

            SerializerFactory   ser   = null;
            DeserializerFactory deser = null;

            // Try to construct a serializerFactory by introspecting for the
            // following:
            // public static create(Class javaType, QName xmlType)
View Full Code Here

            }
            TypeMapping tm = tmr.getOrMakeTypeMapping(encodingStyle);
            desc.setTypeMappingRegistry(tmr);
            desc.setTypeMapping(tm);

            SerializerFactory   ser   = null;
            DeserializerFactory deser = null;

            // Try to construct a serializerFactory by introspecting for the
            // following:
            // public static create(Class javaType, QName xmlType)
View Full Code Here

                                    QName xmlType,
                                    Class sfClass,
                                    Class dfClass,
                                    boolean force) {
        // Instantiate the factory using introspection.
        SerializerFactory   sf =
                BaseSerializerFactory.createFactory(sfClass, javaType, xmlType);
        DeserializerFactory df =
                BaseDeserializerFactory.createFactory(dfClass,
                                                      javaType,
                                                      xmlType);
View Full Code Here

     */
    public static SerializerFactory createFactory(Class factory,
                                                  Class javaType,
                                                  QName xmlType) {

        SerializerFactory sf = null;
        try {
            Method method =
                factory.getMethod("create", CLASS_QNAME_CLASS);
            sf = (SerializerFactory)
                method.invoke(null,
View Full Code Here

                                    QName xmlType,
                                    Class sfClass,
                                    Class dfClass,
                                    boolean force) {
        // Instantiate the factory using introspection.
        SerializerFactory   sf =
                BaseSerializerFactory.createFactory(sfClass, javaType, xmlType);
        DeserializerFactory df =
                BaseDeserializerFactory.createFactory(dfClass,
                                                      javaType,
                                                      xmlType);
View Full Code Here

       
        if (componentTypeQName != null) {
            // if we have a Type QName at this point,
            // this is because ArraySerializer has been instanciated with it
            TypeMapping tm = context.getTypeMapping();
            SerializerFactory factory = (SerializerFactory) tm.getSerializer(
                    componentClass, componentTypeQName);
            while (componentClass.isArray()
                    && factory instanceof ArraySerializerFactory) {
                ArraySerializerFactory asf = (ArraySerializerFactory) factory;
                componentClass = componentClass.getComponentType();
View Full Code Here

                                    QName xmlType,
                                    Class sfClass,
                                    Class dfClass,
                                    boolean force) {
        // Instantiate the factory using introspection.
        SerializerFactory   sf =
                BaseSerializerFactory.createFactory(sfClass, javaType, xmlType);
        DeserializerFactory df =
                BaseDeserializerFactory.createFactory(dfClass,
                                                      javaType,
                                                      xmlType);
View Full Code Here

TOP

Related Classes of org.apache.axis.encoding.SerializerFactory

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.