if (hasFirstCollon) {
prefix = charSeq.subSequence(0, firstcolon).toString();
localname = charSeq.subSequence(firstcolon + 1, charSeq.length()).toString();
if (firstcolon == 0) {
throw new InvalidLexicalValueException("invalid xsd:QName '" + charSeq.toString() + "'");
}
} else {
prefix = EMPTY_PREFIX;
localname = charSeq.toString();
}
String uri = nscontext.getNamespaceURI(prefix);
if (uri == null) {
if (prefix != null && prefix.length() > 0)
throw new InvalidLexicalValueException("Can't resolve prefix: " + prefix);
uri = "";
}
return new QName(uri, localname);