Package org.exist.dom

Examples of org.exist.dom.DocumentSet


        }
    }

    @Test
    public void reindex() {
        DocumentSet docs = configureAndStore(COLLECTION_CONFIG1, XML1, "dropDocument.xml");
        DBBroker broker = null;
        try {
            broker = pool.get(pool.getSecurityManager().getSystemSubject());
            assertNotNull(broker);
View Full Code Here


     * Remove nodes from different levels of the tree and check if the index is
     * correctly updated.
     */
    @Test
    public void xupdateRemove() {
        DocumentSet docs = configureAndStore(COLLECTION_CONFIG2, XML2, "xupdate.xml");
        DBBroker broker = null;
        TransactionManager transact = null;
        Txn transaction = null;
        try {
          broker = pool.get(pool.getSecurityManager().getSystemSubject());
View Full Code Here

     * Remove nodes from different levels of the tree and check if the index is
     * correctly updated.
     */
    @Test
    public void xupdateInsert() {
        DocumentSet docs = configureAndStore(COLLECTION_CONFIG2, XML2, "xupdate.xml");
        DBBroker broker = null;
        TransactionManager transact = null;
        Txn transaction = null;
        try {
          broker = pool.get(pool.getSecurityManager().getSystemSubject());
View Full Code Here

        }
    }

    @Test
    public void xupdateUpdate() {
        DocumentSet docs = configureAndStore(COLLECTION_CONFIG2, XML2, "xupdate.xml");
        DBBroker broker = null;
        TransactionManager transact = null;
        Txn transaction = null;
        try {
            broker = pool.get(pool.getSecurityManager().getSystemSubject());
View Full Code Here

        }
    }

    @Test
    public void xupdateReplace() {
        DocumentSet docs = configureAndStore(COLLECTION_CONFIG2, XML2, "xupdate.xml");
        DBBroker broker = null;
        TransactionManager transact = null;
        Txn transaction = null;
        try {
            broker = pool.get(pool.getSecurityManager().getSystemSubject());
View Full Code Here

        this.generatedFiles = new File[count];
    }

    public File[] generate(DBBroker broker, Collection collection, String xqueryContent) throws SAXException {
        try {
            DocumentSet docs = collection.allDocs(broker, new DefaultDocumentSet(), true);
            XQuery service = broker.getXQueryService();
            XQueryContext context = service.newContext(AccessContext.TEST);
            context.declareVariable("filename", "");
            context.declareVariable("count", "0");
            context.setStaticallyKnownDocuments(docs);
View Full Code Here

        // the expression can be called multiple times, so we need to clear the previous preselectResult
        preselectResult = null;

        RangeIndexWorker index = (RangeIndexWorker) context.getBroker().getIndexController().getWorkerByIndexId(RangeIndex.ID);

        DocumentSet docs = contextSequence.getDocumentSet();
        AtomicValue[] keys = getKeys(contextSequence);
        if (keys.length == 0) {
            return NodeSet.EMPTY_SET;
        }
View Full Code Here

                }
                final RangeIndex.Operator operator = getOperator();

                try {
                    NodeSet inNodes = input.toNodeSet();
                    DocumentSet docs = inNodes.getDocumentSet();
                    result = index.query(getExpressionId(), docs, inNodes, qnames, keys, operator, NodeSet.ANCESTOR);
                } catch (IOException e) {
                    throw new XPathException(this, e.getMessage());
                }
            }
View Full Code Here

        Sequence[] keys = new Sequence[getArgumentCount() - j];
        for (int i = j; i < getArgumentCount(); i++) {
            keys[i - j] = getArgument(i).eval(contextSequence);
        }
        DocumentSet docs = contextSequence.getDocumentSet();

        RangeIndexWorker index = (RangeIndexWorker) context.getBroker().getIndexController().getWorkerByIndexId(RangeIndex.ID);
        try {
            preselectResult = index.queryField(getExpressionId(), docs, useContext ? contextSequence.toNodeSet() : null, fieldSeq, keys, operators, NodeSet.DESCENDANT);
        } catch (IOException e) {
View Full Code Here

        NodeSet result;
        if (preselectResult == null) {
            long start = System.currentTimeMillis();

            DocumentSet docs;
            if (contextSequence == null)
                docs = context.getStaticallyKnownDocuments();
            else
                docs = contextSequence.getDocumentSet();
            NodeSet contextSet = null;
View Full Code Here

TOP

Related Classes of org.exist.dom.DocumentSet

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.