private void deserializeImports(Document document) { TypeSchemaHelper tsh = new TypeSchemaHelper(forceDefaults); for (Node nd = document.getDocumentElement().getFirstChild(); nd != null; nd = nd.getNextSibling()) { if (Node.ELEMENT_NODE == nd.getNodeType() && "configImport".equals(nd.getLocalName()) && MEATADATA_NAMESPACE_URI.equals(nd.getNamespaceURI())) { Element importElement = (Element)nd; String location = importElement.getAttribute("location"); String namespaceURI = importElement.getAttribute("namespace"); if (null == tsh.get(namespaceURI)) { tsh.get(namespaceURI, document.getDocumentURI(), location); } } } }
private void unmarshalDefaultValue(ConfigurationItemMetadataImpl item, Element data) { TypeSchema ts = new TypeSchemaHelper(forceDefaults).get(data.getNamespaceURI()); Object obj = ts.unmarshalDefaultValue(item, data, doValidate); if (null != obj) { item.setDefaultValue(obj); } } }
TypeSchema ts = new TypeSchemaHelper(true).get(JAXWS_TYPES_URI, null, location);
public static String getClassName(QName typeName, boolean qualified) { String baseType = null; TypeSchema ts = null; if (XMLConstants.W3C_XML_SCHEMA_NS_URI.equals(typeName.getNamespaceURI())) { baseType = typeName.getLocalPart(); } else { ts = new TypeSchemaHelper(false).get(typeName.getNamespaceURI()); baseType = ts.getXMLSchemaBaseType(typeName.getLocalPart()); } String className = null; if (null != baseType) { className = JAXBUtils.builtInTypeToJavaType(baseType); if (className != null && !qualified) { int index = className.lastIndexOf('.'); if (index >= 0) { className = className.substring(index + 1); } } } if (null == className) { baseType = typeName.getLocalPart(); className = JAXBUtils.nameToIdentifier(baseType, JAXBUtils.IdentifierType.CLASS); if (qualified) { className = ts.getPackageName() + "." + className; } } return className; }
public Object getValue() { Object o = super.getValue(); if (o instanceof Element) { Element el = (Element)o; QName type = new QName(el.getNamespaceURI(), el.getLocalName()); TypeSchema ts = new TypeSchemaHelper(true).get(type.getNamespaceURI()); if (null == ts) { throw new ConfigurationException(new Message("JAXB_PROPERTY_EDITOR_EXC", LOG, type)); } try { return ts.unmarshal(type, el); } catch (JAXBException ex) { Message msg = new Message("JAXB_PROPERTY_EDITOR_EXC", LOG, type); throw new ConfigurationException(msg, ex); } } return o; } }
public Object getValue() { Object o = super.getValue(); if (o instanceof Element) { Element el = (Element)o; QName type = new QName(el.getNamespaceURI(), el.getLocalName()); TypeSchema ts = new TypeSchemaHelper(true).get(type.getNamespaceURI()); if (null == ts) { throw new ConfigurationException(new Message("JAXB_PROPERTY_EDITOR_EXC", LOG, type)); } try { return ts.unmarshal(type, el); } catch (JAXBException ex) { Message msg = new Message("JAXB_PROPERTY_EDITOR_EXC", LOG, type); throw new ConfigurationException(msg, ex); } } return o; }
public Object getValue() { Object o = super.getValue(); if (o instanceof Element) { Element el = (Element)o; QName type = new QName(el.getNamespaceURI(), el.getLocalName()); TypeSchema ts = new TypeSchemaHelper(true).get(type.getNamespaceURI()); if (null == ts) { throw new ConfigurationException(new Message("JAXB_PROPERTY_EDITOR_EXC", LOG, type)); } try { return ts.unmarshal(type, el); } catch (JAXBException ex) { Message msg = new Message("JAXB_PROPERTY_EDITOR_EXC", LOG, type); throw new ConfigurationException(msg, ex); } } return o; } }
continue; TypeSchema ts = new TypeSchemaHelper(forceDefaults).get(type.getNamespaceURI()); if (ts == null) { throw new ConfigurationException(new Message("NO_TYPESCHEMA_FOR_NAMESPACE_EXC", LOG,
TypeSchema ts = new TypeSchemaHelper(forceDefaults).get(namespaceURI); QName type = null; if (null != ts) {