/*
 * (C) YANDEX LLC, 2014-2015
 *
 * The Source Code called "YoctoDB" available at
 * https://bitbucket.org/yandex/yoctodb is subject to the terms of the
 * Mozilla Public License, v. 2.0 (hereinafter referred to as the "License").
 *
 * A copy of the License is also available at http://mozilla.org/MPL/2.0/.
 */

package com.yandex.yoctodb.immutable;

import com.yandex.yoctodb.util.buf.Buffer;
import net.jcip.annotations.ThreadSafe;
import org.jetbrains.annotations.NotNull;

import java.io.IOException;
import java.util.Collection;

/**
 * Builds immutable {@link Database} from file or {@link Buffer}
 *
 * @author incubos
 */
@ThreadSafe
public abstract class DatabaseReader {
    public final int DEFAULT_QUERY_DEPTH = 2;

    @NotNull
    public Database from(
            @NotNull
            final Buffer buffer) throws IOException {
        return from(buffer, DEFAULT_QUERY_DEPTH, true);
    }

    @NotNull
    public abstract Database from(
            @NotNull
            Buffer b,
            final int bitSetsPerRequest,
            boolean checksum) throws IOException;

    @NotNull
    public abstract Database composite(
            @NotNull
            Collection<Database> databases,
            int bitSetsPerRequest) throws IOException;

    @NotNull
    public Database composite(
            @NotNull
            Collection<Database> databases) throws IOException {
        return composite(databases, DEFAULT_QUERY_DEPTH);
    }
}

@@ -689,16 +689,23 @@
  public 
+static 
 final in
@@ -728,17 +728,17 @@
 DEPTH = 
-2
+4
 ;%0A%0A    @

Increased DEFAULT_QUERY_DEPTH to 4