Home | History | Annotate | Download | only in utils

Lines Matching defs:qname

19  * $Id: QName.java 468655 2006-10-28 07:12:06Z minchau $
36 * [12 Variables and Parameters]) is specified as a QName. If it has a prefix,
44 public class QName implements java.io.Serializable
79 * Constructs an empty QName.
82 public QName(){}
85 * Constructs a new QName with the specified namespace URI and
91 public QName(String namespaceURI, String localName)
97 * Constructs a new QName with the specified namespace URI and
102 * @param validate If true the new QName will be validated and an IllegalArgumentException will
105 public QName(String namespaceURI, String localName, boolean validate)
129 * Constructs a new QName with the specified namespace URI, prefix
137 public QName(String namespaceURI, String prefix, String localName)
143 * Constructs a new QName with the specified namespace URI, prefix
149 * @param validate If true the new QName will be validated and an IllegalArgumentException will
152 public QName(String namespaceURI, String prefix, String localName, boolean validate)
183 * Construct a QName from a string, without namespace resolution. Good
189 public QName(String localName)
195 * Construct a QName from a string, without namespace resolution. Good
199 * @param validate If true the new QName will be validated and an IllegalArgumentException will
202 public QName(String localName, boolean validate)
225 * Construct a QName from a string, resolving the prefix
229 * @param qname Qualified name to resolve
232 public QName(String qname, Stack namespaces)
234 this(qname, namespaces, false);
238 * Construct a QName from a string, resolving the prefix
242 * @param qname Qualified name to resolve
244 * @param validate If true the new QName will be validated and an IllegalArgumentException will
247 public QName(String qname, Stack namespaces, boolean validate)
252 int indexOfNSSep = qname.indexOf(':');
256 prefix = qname.substring(0, indexOfNSSep);
300 ? qname : qname.substring(indexOfNSSep + 1);
316 * Construct a QName from a string, resolving the prefix
320 * @param qname Qualified name to resolve
324 public QName(String qname, Element namespaceContext,
327 this(qname, namespaceContext, resolver, false);
331 * Construct a QName from a string, resolving the prefix
335 * @param qname Qualified name to resolve
338 * @param validate If true the new QName will be validated and an IllegalArgumentException will
341 public QName(String qname, Element namespaceContext,
347 int indexOfNSSep = qname.indexOf(':');
353 String prefix = qname.substring(0, indexOfNSSep);
389 ? qname : qname.substring(indexOfNSSep + 1);
405 * Construct a QName from a string, resolving the prefix
409 * @param qname Qualified name to resolve
412 public QName(String qname, PrefixResolver resolver)
414 this(qname, resolver, false);
418 * Construct a QName from a string, resolving the prefix
422 * @param qname Qualified name to resolve
424 * @param validate If true the new QName will be validated and an IllegalArgumentException will
427 public QName(String qname, PrefixResolver resolver, boolean validate)
433 int indexOfNSSep = qname.indexOf(':');
437 prefix = qname.substring(0, indexOfNSSep);
455 _localName = qname.substring(indexOfNSSep + 1);
466 _localName = qname;
599 * the passed object is a QName and it matches
610 if (object instanceof QName) {
611 QName qname = (QName) object;
613 String thatnamespace = qname.getNamespaceURI();
615 return getLocalName().equals(qname.getLocalName())
625 * Given a string, create and return a QName object
628 * @param name String to use to create QName
630 * @return a QName object
632 public static QName getQNameFromString(String name)
636 QName qname;
641 qname = new QName(null, s1);
643 qname = new QName(s1, s2);
645 return qname;
683 * @param qname Input name
687 public static String getLocalPart(String qname)
690 int index = qname.indexOf(':');
692 return (index < 0) ? qname : qname.substring(index + 1);
698 * @param qname Input name
702 public static String getPrefixPart(String qname)
705 int index = qname.indexOf(':');
707 return (index >= 0) ? qname.substring(0, index) : "";