/** * Parses the string representation of SCD. * * <p> * This method involves parsing the path expression and preparing the in-memory * structure, so this is useful when you plan to use the same SCD against * different context node multiple times. * * <p> * If you want to evaluate SCD just once, use {@link XSComponent#select} methods. * * @param path * the string representation of SCD, such as "/foo/bar". * @param nsContext * Its {@link NamespaceContext#getNamespaceURI(String)} is used * to resolve prefixes in the SCD to the namespace URI. */ public static SCD create(String path, NamespaceContext nsContext) throws java.text.ParseException { try { SCDParser p = new SCDParser(path,nsContext); List<?> list = p.RelativeSchemaComponentPath(); return new SCDImpl(path,list.toArray(new Step[list.size()])); } catch (TokenMgrError e) { throw setCause(new java.text.ParseException(e.getMessage(), -1 ),e); } catch (ParseException e) { throw setCause(new java.text.ParseException(e.getMessage(), e.currentToken.beginColumn ),e); } }
/** * Parses the string representation of SCD. * * <p> * This method involves parsing the path expression and preparing the in-memory * structure, so this is useful when you plan to use the same SCD against * different context node multiple times. * * <p> * If you want to evaluate SCD just once, use {@link XSComponent#select} methods. * * @param path * the string representation of SCD, such as "/foo/bar". * @param nsContext * Its {@link NamespaceContext#getNamespaceURI(String)} is used * to resolve prefixes in the SCD to the namespace URI. */ public static SCD create(String path, NamespaceContext nsContext) throws java.text.ParseException { try { SCDParser p = new SCDParser(path,nsContext); List<?> list = p.RelativeSchemaComponentPath(); return new SCDImpl(path,list.toArray(new Step[list.size()])); } catch (TokenMgrError e) { throw setCause(new java.text.ParseException(e.getMessage(), -1 ),e); } catch (ParseException e) { throw setCause(new java.text.ParseException(e.getMessage(), e.currentToken.beginColumn ),e); } }
/** * Parses the string representation of SCD. * * <p> * This method involves parsing the path expression and preparing the in-memory * structure, so this is useful when you plan to use the same SCD against * different context node multiple times. * * <p> * If you want to evaluate SCD just once, use {@link XSComponent#select} methods. * * @param path * the string representation of SCD, such as "/foo/bar". * @param nsContext * Its {@link NamespaceContext#getNamespaceURI(String)} is used * to resolve prefixes in the SCD to the namespace URI. */ public static SCD create(String path, NamespaceContext nsContext) throws java.text.ParseException { try { SCDParser p = new SCDParser(path,nsContext); List<?> list = p.RelativeSchemaComponentPath(); return new SCDImpl(path,list.toArray(new Step[list.size()])); } catch (TokenMgrError e) { throw setCause(new java.text.ParseException(e.getMessage(), -1 ),e); } catch (ParseException e) { throw setCause(new java.text.ParseException(e.getMessage(), e.currentToken.beginColumn ),e); } }
/** * Parses the string representation of SCD. * * <p> * This method involves parsing the path expression and preparing the in-memory * structure, so this is useful when you plan to use the same SCD against * different context node multiple times. * * <p> * If you want to evaluate SCD just once, use {@link XSComponent#select} methods. * * @param path * the string representation of SCD, such as "/foo/bar". * @param nsContext * Its {@link NamespaceContext#getNamespaceURI(String)} is used * to resolve prefixes in the SCD to the namespace URI. */ public static SCD create(String path, NamespaceContext nsContext) throws java.text.ParseException { try { SCDParser p = new SCDParser(path,nsContext); List<?> list = p.RelativeSchemaComponentPath(); return new SCDImpl(path,list.toArray(new Step[list.size()])); } catch (TokenMgrError e) { throw setCause(new java.text.ParseException(e.getMessage(), -1 ),e); } catch (ParseException e) { throw setCause(new java.text.ParseException(e.getMessage(), e.currentToken.beginColumn ),e); } }
/** * Parses the string representation of SCD. * * <p> * This method involves parsing the path expression and preparing the in-memory * structure, so this is useful when you plan to use the same SCD against * different context node multiple times. * * <p> * If you want to evaluate SCD just once, use {@link XSComponent#select} methods. * * @param path * the string representation of SCD, such as "/foo/bar". * @param nsContext * Its {@link NamespaceContext#getNamespaceURI(String)} is used * to resolve prefixes in the SCD to the namespace URI. */ public static SCD create(String path, NamespaceContext nsContext) throws java.text.ParseException { try { SCDParser p = new SCDParser(path,nsContext); List<?> list = p.RelativeSchemaComponentPath(); return new SCDImpl(path,list.toArray(new Step[list.size()])); } catch (TokenMgrError e) { throw setCause(new java.text.ParseException(e.getMessage(), -1 ),e); } catch (ParseException e) { throw setCause(new java.text.ParseException(e.getMessage(), e.currentToken.beginColumn ),e); } }