public XmlNs[] xmlns() { return core.xmlns(); }
public Map<String,String> getXmlNs(String namespaceUri) { if(xmlNsCache==null) { xmlNsCache = new HashMap<String,Map<String,String>>(); for (ClassInfoImpl<T, C, F, M> ci : beans().values()) { XmlSchema xs = reader.getPackageAnnotation( XmlSchema.class, ci.getClazz(), null ); if(xs==null) continue; String uri = xs.namespace(); Map<String,String> m = xmlNsCache.get(uri); if(m==null) xmlNsCache.put(uri,m=new HashMap<String, String>()); for( XmlNs xns : xs.xmlns() ) { m.put(xns.prefix(),xns.namespaceURI()); } } } Map<String,String> r = xmlNsCache.get(namespaceUri); if(r!=null) return r; else return Collections.emptyMap(); }
public XmlNs[] xmlns() { return core.xmlns(); }
public Map<String,String> getXmlNs(String namespaceUri) { if(xmlNsCache==null) { xmlNsCache = new HashMap<String,Map<String,String>>(); for (ClassInfoImpl<T, C, F, M> ci : beans().values()) { XmlSchema xs = reader.getPackageAnnotation( XmlSchema.class, ci.getClazz(), null ); if(xs==null) continue; String uri = xs.namespace(); Map<String,String> m = xmlNsCache.get(uri); if(m==null) xmlNsCache.put(uri,m=new HashMap<String, String>()); for( XmlNs xns : xs.xmlns() ) { m.put(xns.prefix(),xns.namespaceURI()); } } } Map<String,String> r = xmlNsCache.get(namespaceUri); if(r!=null) return r; else return Collections.emptyMap(); }
public XmlNs[] xmlns() { return core.xmlns(); }
public XmlNs[] xmlns() { return core.xmlns(); }
protected String getPrefix(String namespaceURI, XmlSchema xmlSchema) { if (xmlSchema != null) { for (XmlNs xmlns : xmlSchema.xmlns()) { if (xmlns.namespaceURI().equals(namespaceURI)) { return xmlns.prefix(); } } } return XMLConstants.DEFAULT_NS_PREFIX; }
protected String getPrefix(String namespaceURI, XmlSchema xmlSchema) { if (xmlSchema != null) { for (XmlNs xmlns : xmlSchema.xmlns()) { if (xmlns.namespaceURI().equals(namespaceURI)) { return xmlns.prefix(); } } } return XMLConstants.DEFAULT_NS_PREFIX; }
protected String getPrefix(String namespaceURI, XmlSchema xmlSchema) { if (xmlSchema != null) { for (XmlNs xmlns : xmlSchema.xmlns()) { if (xmlns.namespaceURI().equals(namespaceURI)) { return xmlns.prefix(); } } } return XMLConstants.DEFAULT_NS_PREFIX; }
/** * Gets the specified namespace prefixes for this package. * * @return The specified namespace prefixes for this package. */ public Map<String, String> getSpecifiedNamespacePrefixes() { HashMap<String, String> namespacePrefixes = new HashMap<String, String>(); if (xmlSchema != null) { XmlNs[] xmlns = xmlSchema.xmlns(); if (xmlns != null) { for (XmlNs ns : xmlns) { namespacePrefixes.put(ns.namespaceURI(), ns.prefix()); } } } return namespacePrefixes; }
/** * Gets the specified namespace prefixes for this package. * * @return The specified namespace prefixes for this package. */ public Map<String, String> getSpecifiedNamespacePrefixes() { HashMap<String, String> namespacePrefixes = new HashMap<String, String>(); if (xmlSchema != null) { XmlNs[] xmlns = xmlSchema.xmlns(); if (xmlns != null) { for (XmlNs ns : xmlns) { namespacePrefixes.put(ns.namespaceURI(), ns.prefix()); } } } return namespacePrefixes; }
private static String getPrefix(final Package targetPackage, String namespaceURI) { String prefix; final Map<String, String> namespacePrefixes = new HashMap<String, String>(); if (targetPackage != null) { final XmlSchema xmlSchemaAnnotation = targetPackage .getAnnotation(XmlSchema.class); if (xmlSchemaAnnotation != null) { for (XmlNs xmlns : xmlSchemaAnnotation.xmlns()) { namespacePrefixes.put(xmlns.namespaceURI(), xmlns.prefix()); } } } prefix = namespacePrefixes.get(namespaceURI); return prefix; }
/** * Gets the specified namespace prefixes for this package. * * @return The specified namespace prefixes for this package. */ public Map<String, String> getSpecifiedNamespacePrefixes() { HashMap<String, String> namespacePrefixes = new HashMap<String, String>(); if (xmlSchema != null) { XmlNs[] xmlns = xmlSchema.xmlns(); if (xmlns != null) { for (XmlNs ns : xmlns) { if (!ns.prefix().isEmpty()) { namespacePrefixes.put(ns.namespaceURI(), ns.prefix()); } } } } return namespacePrefixes; }
/** * Gets the specified namespace prefixes for this package. * * @return The specified namespace prefixes for this package. */ public Map<String, String> getSpecifiedNamespacePrefixes() { HashMap<String, String> namespacePrefixes = new HashMap<String, String>(); if (xmlSchema != null) { XmlNs[] xmlns = xmlSchema.xmlns(); if (xmlns != null) { for (XmlNs ns : xmlns) { if (!ns.prefix().isEmpty()) { namespacePrefixes.put(ns.namespaceURI(), ns.prefix()); } } } } return namespacePrefixes; }
public Map<String,String> getXmlNs(String namespaceUri) { if(xmlNsCache==null) { xmlNsCache = new HashMap<String,Map<String,String>>(); for (ClassInfoImpl<T, C, F, M> ci : beans().values()) { XmlSchema xs = reader.getPackageAnnotation( XmlSchema.class, ci.getClazz(), null ); if(xs==null) continue; String uri = xs.namespace(); Map<String,String> m = xmlNsCache.get(uri); if(m==null) xmlNsCache.put(uri,m=new HashMap<String, String>()); for( XmlNs xns : xs.xmlns() ) { m.put(xns.prefix(),xns.namespaceURI()); } } } Map<String,String> r = xmlNsCache.get(namespaceUri); if(r!=null) return r; else return Collections.emptyMap(); }
public Map<String,String> getXmlNs(String namespaceUri) { if(xmlNsCache==null) { xmlNsCache = new HashMap<String,Map<String,String>>(); for (ClassInfoImpl<T, C, F, M> ci : beans().values()) { XmlSchema xs = reader.getPackageAnnotation( XmlSchema.class, ci.getClazz(), null ); if(xs==null) continue; String uri = xs.namespace(); Map<String,String> m = xmlNsCache.get(uri); if(m==null) xmlNsCache.put(uri,m=new HashMap<String, String>()); for( XmlNs xns : xs.xmlns() ) { m.put(xns.prefix(),xns.namespaceURI()); } } } Map<String,String> r = xmlNsCache.get(namespaceUri); if(r!=null) return r; else return Collections.emptyMap(); }
for (final XmlNs ns : p.getAnnotation(XmlSchema.class).xmlns()) { testingClass = p.getName(); final String namespace = ns.namespaceURI();
XmlNs[] xmlns = xmlSchema.xmlns(); for (XmlNs next : xmlns) { info.getNamespaceResolver().put(next.prefix(), next.namespaceURI());