[RocksJava] Incorporated review comments D28947

This commit is contained in:
fyrz 2014-11-15 00:14:36 +01:00
parent 07cd3c42a2
commit 4947a0674f
2 changed files with 4 additions and 3 deletions

View File

@ -32,6 +32,8 @@ public enum InfoLogLevel {
* @param value byte representation of InfoLogLevel.
*
* @return {@link org.rocksdb.InfoLogLevel} instance or null.
* @throws java.lang.IllegalArgumentException if an invalid
* value is provided.
*/
public static InfoLogLevel getInfoLogLevel(byte value) {
for (InfoLogLevel infoLogLevel : InfoLogLevel.values()) {
@ -39,6 +41,7 @@ public enum InfoLogLevel {
return infoLogLevel;
}
}
return null;
throw new IllegalArgumentException(
"Illegal value provided for InfoLogLevel.");
}
}

View File

@ -604,7 +604,6 @@ public class Options extends RocksObject
@Override
public Options setMemTableConfig(MemTableConfig config)
throws RocksDBException {
assert(isInitialized());
memTableConfig_ = config;
setMemTableFactory(nativeHandle_, config.newMemTableFactoryHandle());
return this;
@ -612,7 +611,6 @@ public class Options extends RocksObject
@Override
public Options setRateLimiterConfig(RateLimiterConfig config) {
assert(isInitialized());
rateLimiterConfig_ = config;
setRateLimiter(nativeHandle_, config.newRateLimiterHandle());
return this;