Examples of IndexOutputStream


Examples of org.apache.jackrabbit.core.query.lucene.directory.IndexOutputStream

     * @throws IOException if an error occurs while creating the
     * output stream.
     */
    private void initOut() throws IOException {
        if (out == null) {
            OutputStream os = new IndexOutputStream(dir.createOutput(fileName));
            out = new BufferedWriter(new OutputStreamWriter(os));
        }
    }
View Full Code Here

Examples of org.apache.jackrabbit.core.query.lucene.directory.IndexOutputStream

     * @throws IOException if an error occurs while creating the
     * output stream.
     */
    private void initOut() throws IOException {
        if (out == null) {
            OutputStream os = new IndexOutputStream(dir.createOutput(fileName));
            out = new BufferedWriter(new OutputStreamWriter(os));
        }
    }
View Full Code Here

Examples of org.apache.jackrabbit.core.query.lucene.directory.IndexOutputStream

        // increment generation
        generation++;
        String newName = getFileName();
        boolean success = false;
        try {
            OutputStream out = new BufferedOutputStream(new IndexOutputStream(
                    directory.createOutput(newName)));
            try {
                log.debug("Writing IndexInfos {}", newName);
                DataOutputStream dataOut = new DataOutputStream(out);
                dataOut.writeInt(WITH_GENERATION);
View Full Code Here

Examples of org.apache.jackrabbit.core.query.lucene.directory.IndexOutputStream

        // increment generation
        generation++;
        String newName = getFileName();
        boolean success = false;
        try {
            OutputStream out = new IndexOutputStream(
                    directory.createOutput(newName));
            try {
                log.debug("Writing IndexInfos {}", newName);
                DataOutputStream dataOut = new DataOutputStream(out);
                dataOut.writeInt(WITH_GENERATION);
                dataOut.writeInt(counter);
                dataOut.writeInt(indexes.size());
                for (Iterator it = iterator(); it.hasNext(); ) {
                    IndexInfo info = (IndexInfo) it.next();
                    dataOut.writeUTF(info.getName());
                    dataOut.writeLong(info.getGeneration());
                    log.debug("  + {}:{}", info.getName(), info.getGeneration());
                }
            } finally {
                out.close();
            }
            lastModified = System.currentTimeMillis();
            success = true;
        } finally {
            if (!success) {
View Full Code Here

Examples of org.apache.jackrabbit.core.query.lucene.directory.IndexOutputStream

        // increment generation
        generation++;
        String newName = getFileName();
        boolean success = false;
        try {
            OutputStream out = new BufferedOutputStream(new IndexOutputStream(
                    directory.createOutput(newName)));
            try {
                log.debug("Writing IndexInfos {}", newName);
                DataOutputStream dataOut = new DataOutputStream(out);
                dataOut.writeInt(WITH_GENERATION);
View Full Code Here

Examples of org.apache.jackrabbit.core.query.lucene.directory.IndexOutputStream

        // increment generation
        generation++;
        String newName = getFileName();
        boolean success = false;
        try {
            OutputStream out = new BufferedOutputStream(new IndexOutputStream(
                    directory.createOutput(newName)));
            try {
                log.debug("Writing IndexInfos {}", newName);
                DataOutputStream dataOut = new DataOutputStream(out);
                dataOut.writeInt(WITH_GENERATION);
View Full Code Here

Examples of org.apache.jackrabbit.core.query.lucene.directory.IndexOutputStream

        // increment generation
        generation++;
        String newName = getFileName();
        boolean success = false;
        try {
            OutputStream out = new BufferedOutputStream(new IndexOutputStream(
                    directory.createOutput(newName)));
            try {
                log.debug("Writing IndexInfos {}", newName);
                DataOutputStream dataOut = new DataOutputStream(out);
                dataOut.writeInt(WITH_GENERATION);
View Full Code Here

Examples of org.apache.jackrabbit.core.query.lucene.directory.IndexOutputStream

     * @throws IOException if an error occurs while creating the
     * output stream.
     */
    private void initOut() throws IOException {
        if (out == null) {
            OutputStream os = new IndexOutputStream(dir.createOutput(fileName));
            out = new BufferedWriter(new OutputStreamWriter(os));
        }
    }
View Full Code Here

Examples of org.apache.jackrabbit.core.query.lucene.directory.IndexOutputStream

        // do not write if not dirty
        if (!dirty) {
            return;
        }

        OutputStream out = new IndexOutputStream(dir.createOutput(name + ".new"));
        try {
            DataOutputStream dataOut = new DataOutputStream(out);
            dataOut.writeInt(counter);
            dataOut.writeInt(indexes.size());
            for (int i = 0; i < indexes.size(); i++) {
                dataOut.writeUTF(getName(i));
            }
        } finally {
            out.close();
        }
        // delete old
        if (dir.fileExists(name)) {
            dir.deleteFile(name);
        }
View Full Code Here

Examples of org.apache.jackrabbit.core.query.lucene.directory.IndexOutputStream

     * @throws IOException if an error occurs while creating the
     * output stream.
     */
    private void initOut() throws IOException {
        if (out == null) {
            OutputStream os = new IndexOutputStream(dir.createOutput(REDO_LOG));
            out = new BufferedWriter(new OutputStreamWriter(os));
        }
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.