Examples of BeanSerializerFactory


Examples of org.apache.axis.encoding.ser.BeanSerializerFactory

        Call call = null;
            Service service = new Service();
            call = (Call) service.createCall();

            call.registerTypeMapping(Bean.class, m_beanQName,
                new BeanSerializerFactory(Bean.class, m_beanQName),
                new BeanDeserializerFactory(Bean.class, m_beanQName));
        return call;
    }
View Full Code Here

Examples of org.apache.axis.encoding.ser.BeanSerializerFactory

    public void testGlobalTypes() throws Exception {
        Call call = new Call("http://localhost:8080/jws/GlobalTypeTest.jws");
        QName qname = new QName("http://globalTypeTest", "GlobalType");
        call.registerTypeMapping(GlobalBean.class, qname,
                    new BeanSerializerFactory(GlobalBean.class, qname),
                    new BeanDeserializerFactory(GlobalBean.class, qname));
        GlobalBean bean = new GlobalBean();
        bean.setIntValue(4);
        GlobalBean ret = (GlobalBean)call.invoke("echo", new Object [] { bean });
        assertEquals(4, ret.getIntValue());
View Full Code Here

Examples of org.apache.axis.encoding.ser.BeanSerializerFactory

                    }
                }
                td.setXmlType(q);
                TypeDesc.registerTypeDescForClass(cls, td);
            }
            mTypeMapping.register(cls, q, new BeanSerializerFactory(cls, q),
            /*
             * NOTE jcolwell@bea.com 2004-Oct-11 -- should check that the type
             * to deserialize has a default contructor but with this setup there
             * is no way to know if it is used only in serialization.
             */
 
View Full Code Here

Examples of org.apache.axis.encoding.ser.BeanSerializerFactory

                            TypeDesc.registerTypeDescForClass(cls, td);
                        } else {
                            td = null;
                        }
                        mTypeMapping.register(cls, q,
                                    new BeanSerializerFactory(cls, q),
                                    /*
                                     * NOTE jcolwell@bea.com 2004-Oct-11 --
                                     * should check that the type to deserialize
                                     * has a default contructor but with this
                                     * setup there is no way to know if it is
View Full Code Here

Examples of org.apache.axis.encoding.ser.BeanSerializerFactory

        engine.init();

        // And deploy the type mapping
        Class javaType = Data.class;
        QName xmlType = new QName("urn:foo", "Data");
        BeanSerializerFactory   sf = new BeanSerializerFactory(javaType, xmlType);
        BeanDeserializerFactory df = new BeanDeserializerFactory(javaType, xmlType);

        TypeMappingRegistry tmr = engine.getTypeMappingRegistry();
        TypeMapping tm =
                tmr.getOrMakeTypeMapping(Constants.URI_DEFAULT_SOAP_ENC);
View Full Code Here

Examples of org.apache.axis.encoding.ser.BeanSerializerFactory

             * and getDeserializer() are called, this QName is returned and
             * these methods do not need to worry about creating a serializer.
             */
            internalRegister( javaType,
                              xmlType,
                              new BeanSerializerFactory(javaType, xmlType),
                              new BeanDeserializerFactory(javaType, xmlType) );
        }

        //log.debug("getTypeQName xmlType =" + xmlType);
        return xmlType;
View Full Code Here

Examples of org.apache.axis.encoding.ser.BeanSerializerFactory

                }
                try {
                    javaType = ClassUtils.forName(className);
                    internalRegister(javaType,
                                     xmlType,
                                     new BeanSerializerFactory(javaType, xmlType),
                                     new BeanDeserializerFactory(javaType, xmlType));
                } catch (ClassNotFoundException e) {
                }
            }
        }
View Full Code Here

Examples of org.apache.axis.encoding.ser.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;
            }
        }
View Full Code Here

Examples of org.apache.axis.encoding.ser.BeanSerializerFactory

        // If no factory is found, use the BeanSerializerFactory
        // if applicable, otherwise issue errors and return anyType
        if (factory == null) {
            if (isBeanCompatible(type, true)) {
                factory = new BeanSerializerFactory(type, getTypeQName(type));
            } else {
                return Constants.NS_PREFIX_SCHEMA_XSD + ":" +
                    Constants.XSD_ANYTYPE.getLocalPart();
            }
        }
View Full Code Here

Examples of org.apache.axis.encoding.ser.BeanSerializerFactory

                clazz = ClassUtils.loadClass(iterator.next().toString(), getClass());
                String localName = Types.getLocalNameFromFullName(clazz.getName());
                QName xmlType = new QName(Namespaces.makeNamespace(clazz.getName()), localName);

                registry.getDefaultTypeMapping().register(clazz, xmlType,
                        new BeanSerializerFactory(clazz, xmlType), new BeanDeserializerFactory(clazz, xmlType));
            }
        }
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.