Rename FastLzFramed* to FastLzFrame*

This commit is contained in:
Trustin Lee 2014-08-13 22:55:05 -07:00
parent d315bbaa14
commit f311012455
4 changed files with 17 additions and 17 deletions

View File

@ -19,7 +19,7 @@ package io.netty.handler.codec.compression;
* Core of FastLZ compression algorithm.
*
* This class provides methods for compression and decompression of buffers and saves
* constants which use by {@link FastLzFramedEncoder} and {@link FastLzFramedDecoder}.
* constants which use by {@link FastLzFrameEncoder} and {@link FastLzFrameDecoder}.
*
* This is refactored code of <a href="https://code.google.com/p/jfastlz/">jfastlz</a>
* library written by William Kinney.

View File

@ -30,7 +30,7 @@ import static io.netty.handler.codec.compression.FastLz.*;
*
* See <a href="https://github.com/netty/netty/issues/2750">FastLZ format</a>.
*/
public class FastLzFramedDecoder extends ByteToMessageDecoder {
public class FastLzFrameDecoder extends ByteToMessageDecoder {
/**
* Current state of decompression.
*/
@ -77,7 +77,7 @@ public class FastLzFramedDecoder extends ByteToMessageDecoder {
/**
* Creates the fastest FastLZ decoder without checksum calculation.
*/
public FastLzFramedDecoder() {
public FastLzFrameDecoder() {
this(false);
}
@ -91,7 +91,7 @@ public class FastLzFramedDecoder extends ByteToMessageDecoder {
* Note, that in this case decoder will use {@link java.util.zip.Adler32}
* as a default checksum calculator.
*/
public FastLzFramedDecoder(boolean validateChecksums) {
public FastLzFrameDecoder(boolean validateChecksums) {
this(validateChecksums ? new Adler32() : null);
}
@ -102,7 +102,7 @@ public class FastLzFramedDecoder extends ByteToMessageDecoder {
* the {@link Checksum} instance to use to check data for integrity.
* You may set {@code null} if you do not want to validate checksum of each block.
*/
public FastLzFramedDecoder(Checksum checksum) {
public FastLzFrameDecoder(Checksum checksum) {
this.checksum = checksum;
}

View File

@ -29,7 +29,7 @@ import static io.netty.handler.codec.compression.FastLz.*;
*
* See <a href="https://github.com/netty/netty/issues/2750">FastLZ format</a>.
*/
public class FastLzFramedEncoder extends MessageToByteEncoder<ByteBuf> {
public class FastLzFrameEncoder extends MessageToByteEncoder<ByteBuf> {
/**
* Compression level.
*/
@ -43,7 +43,7 @@ public class FastLzFramedEncoder extends MessageToByteEncoder<ByteBuf> {
/**
* Creates a FastLZ encoder without checksum calculator and with auto detection of compression level.
*/
public FastLzFramedEncoder() {
public FastLzFrameEncoder() {
this(LEVEL_AUTO, null);
}
@ -55,7 +55,7 @@ public class FastLzFramedEncoder extends MessageToByteEncoder<ByteBuf> {
* 1 - Level 1 is the fastest compression and generally useful for short data.
* 2 - Level 2 is slightly slower but it gives better compression ratio.
*/
public FastLzFramedEncoder(int level) {
public FastLzFrameEncoder(int level) {
this(level, null);
}
@ -66,10 +66,10 @@ public class FastLzFramedEncoder extends MessageToByteEncoder<ByteBuf> {
* @param validateChecksums
* If true, the checksum of each block will be calculated and this value
* will be added to the header of block.
* By default {@link FastLzFramedEncoder} uses {@link java.util.zip.Adler32}
* By default {@link FastLzFrameEncoder} uses {@link java.util.zip.Adler32}
* for checksum calculation.
*/
public FastLzFramedEncoder(boolean validateChecksums) {
public FastLzFrameEncoder(boolean validateChecksums) {
this(LEVEL_AUTO, validateChecksums ? new Adler32() : null);
}
@ -84,7 +84,7 @@ public class FastLzFramedEncoder extends MessageToByteEncoder<ByteBuf> {
* the {@link Checksum} instance to use to check data for integrity.
* You may set {@code null} if you don't want to validate checksum of each block.
*/
public FastLzFramedEncoder(int level, Checksum checksum) {
public FastLzFrameEncoder(int level, Checksum checksum) {
super(false);
if (level != LEVEL_AUTO && level != LEVEL_1 && level != LEVEL_2) {
throw new IllegalArgumentException(String.format(

View File

@ -30,12 +30,12 @@ public class FastLzIntegrationTest extends IntegrationTest {
@Override
protected EmbeddedChannel createEncoderEmbeddedChannel() {
return new EmbeddedChannel(new FastLzFramedEncoder(true));
return new EmbeddedChannel(new FastLzFrameEncoder(true));
}
@Override
protected EmbeddedChannel createDecoderEmbeddedChannel() {
return new EmbeddedChannel(new FastLzFramedDecoder(true));
return new EmbeddedChannel(new FastLzFrameDecoder(true));
}
}
@ -43,23 +43,23 @@ public class FastLzIntegrationTest extends IntegrationTest {
@Override
protected EmbeddedChannel createEncoderEmbeddedChannel() {
return new EmbeddedChannel(new FastLzFramedEncoder(rand.nextBoolean()));
return new EmbeddedChannel(new FastLzFrameEncoder(rand.nextBoolean()));
}
@Override
protected EmbeddedChannel createDecoderEmbeddedChannel() {
return new EmbeddedChannel(new FastLzFramedDecoder(rand.nextBoolean()));
return new EmbeddedChannel(new FastLzFrameDecoder(rand.nextBoolean()));
}
}
@Override
protected EmbeddedChannel createEncoderEmbeddedChannel() {
return new EmbeddedChannel(new FastLzFramedEncoder(rand.nextBoolean()));
return new EmbeddedChannel(new FastLzFrameEncoder(rand.nextBoolean()));
}
@Override
protected EmbeddedChannel createDecoderEmbeddedChannel() {
return new EmbeddedChannel(new FastLzFramedDecoder(rand.nextBoolean()));
return new EmbeddedChannel(new FastLzFrameDecoder(rand.nextBoolean()));
}
@Override // test batched flow of data