From cea2be20b66344514fc7cd42b1d06fe269985994 Mon Sep 17 00:00:00 2001 From: Ankit Gupta Date: Mon, 21 Apr 2014 20:27:09 -0700 Subject: [PATCH] Fix formatting --- java/org/rocksdb/Options.java | 14 +++++++------- java/org/rocksdb/ReadOptions.java | 1 - java/rocksjni/options.cc | 4 ++-- 3 files changed, 9 insertions(+), 10 deletions(-) diff --git a/java/org/rocksdb/Options.java b/java/org/rocksdb/Options.java index 95081eb75..c05e0d5e4 100644 --- a/java/org/rocksdb/Options.java +++ b/java/org/rocksdb/Options.java @@ -143,19 +143,19 @@ public class Options { assert(isInitialized()); return blockSize(nativeHandle_); } - + /** * Filters are stored in rocksdb and are consulted automatically * by rocksdb to decide whether or not to read some * information from disk. In many cases, a filter can cut down the * number of disk seeks form a handful to a single disk seek per * DB::Get() call. - * - * This function a new filter policy that uses a bloom filter - * with approximately the specified number of bits per key. - * A good value for bitsPerKey is 10, which yields a filter + * + * This function a new filter policy that uses a bloom filter + * with approximately the specified number of bits per key. + * A good value for bitsPerKey is 10, which yields a filter * with ~ 1% false positive rate. - * + * * @param Bits per key for bloom filter. * @return the instance of the current Options. * @see RocksDB.open() @@ -1259,7 +1259,7 @@ public class Options { private native void useFixedLengthPrefixExtractor( long handle, int prefixLength); - + private native void createBloomFilter0(long handle, int bitsPerKey); long nativeHandle_; diff --git a/java/org/rocksdb/ReadOptions.java b/java/org/rocksdb/ReadOptions.java index c9ab547cc..aead12ec8 100644 --- a/java/org/rocksdb/ReadOptions.java +++ b/java/org/rocksdb/ReadOptions.java @@ -162,4 +162,3 @@ public class ReadOptions { return nativeHandle_ != 0; } } - diff --git a/java/rocksjni/options.cc b/java/rocksjni/options.cc index f11f6961b..29108e44c 100644 --- a/java/rocksjni/options.cc +++ b/java/rocksjni/options.cc @@ -128,12 +128,12 @@ jlong Java_org_rocksdb_Options_statisticsPtr( void Java_org_rocksdb_Options_createBloomFilter0( JNIEnv* env, jobject jobj, jlong jhandle, jint jbits_per_key) { rocksdb::Options* opt = reinterpret_cast(jhandle); - + // Delete previously allocated pointer if(opt->filter_policy) { delete opt->filter_policy; } - + opt->filter_policy = rocksdb::NewBloomFilterPolicy(jbits_per_key); }