Here you can find the source of createQNameWithCustomNamespace(String key)
Parameter | Description |
---|---|
key | Local element name. |
public static QName createQNameWithCustomNamespace(String key)
//package com.java2s; import javax.xml.namespace.QName; public class Main { /**/*from w w w. java 2s . com*/ * Default namespace prefix */ public static final String CUSTOM_NAMESPACE_PREFIX = "s"; /** * Default namespace URI */ public static final String CUSTOM_NAMESPACE_URI = "SAR:"; /** * @param key Local element name. */ public static QName createQNameWithCustomNamespace(String key) { return new QName(CUSTOM_NAMESPACE_URI, key, CUSTOM_NAMESPACE_PREFIX); } }