try {
String encodingStyle = mapping.getEncodingStyle();
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)
// public <constructor>(Class javaType, QName xmlType)
// public <constructor>()
//
// The BaseSerializerFactory createFactory() method is a utility
// that does this for us.
//log.debug("start creating sf and df");
if (mapping.getSerializerName() != null &&
!mapping.getSerializerName().equals("")) {
ser = BaseSerializerFactory.createFactory(mapping.getSerializer(),
mapping.getLanguageSpecificType(),
mapping.getQName());
}
//log.debug("set ser factory");
if (mapping.getDeserializerName() != null &&
!mapping.getDeserializerName().equals("")) {
deser = BaseDeserializerFactory.createFactory(mapping.getDeserializer(),
mapping.getLanguageSpecificType(),
mapping.getQName());
}
//log.debug("set dser factory");
tm.register( mapping.getLanguageSpecificType(), mapping.getQName(), ser, deser);
//log.debug("registered");
} catch (ClassNotFoundException e) {
log.error(Messages.getMessage("unabletoDeployTypemapping00", mapping.getQName().toString()), e);
throw new WSDDNonFatalException(e);
} catch (Exception e) {