From: Wolfgang M. M. <wol...@us...> - 2004-06-29 14:23:35
|
Update of /cvsroot/exist/eXist-1.0/src/org/exist/xquery/value In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv29319/src/org/exist/xquery/value Modified Files: QNameValue.java Type.java Log Message: Added dynamic namespace constructor. Index: QNameValue.java =================================================================== RCS file: /cvsroot/exist/eXist-1.0/src/org/exist/xquery/value/QNameValue.java,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** QNameValue.java 28 May 2004 10:54:10 -0000 1.2 --- QNameValue.java 29 Jun 2004 14:23:26 -0000 1.3 *************** *** 52,59 **** */ public String getStringValue() throws XPathException { ! String prefix = context.getPrefixForURI(qname.getNamespaceURI()); ! if (prefix == null) ! throw new XPathException( ! "namespace " + qname.getNamespaceURI() + " is not defined"); return qname.toString(); } --- 52,61 ---- */ public String getStringValue() throws XPathException { ! if(qname.needsNamespaceDecl()) { ! String prefix = context.getPrefixForURI(qname.getNamespaceURI()); ! if (prefix == null) ! throw new XPathException( ! "namespace " + qname.getNamespaceURI() + " is not defined"); ! } return qname.toString(); } Index: Type.java =================================================================== RCS file: /cvsroot/exist/eXist-1.0/src/org/exist/xquery/value/Type.java,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** Type.java 17 Jun 2004 13:18:39 -0000 1.2 --- Type.java 29 Jun 2004 14:23:26 -0000 1.3 *************** *** 53,57 **** public final static int COMMENT = 5; public final static int DOCUMENT = 6; ! public final static int NAMESPACE = 7; public final static int EMPTY = 10; --- 53,57 ---- public final static int COMMENT = 5; public final static int DOCUMENT = 6; ! public final static int NAMESPACE = 500; public final static int EMPTY = 10; |