提交 548e9ed5 编写于 作者: S Stephan Ewen

[hotfix] [core] Fix checkstyle in flink-core:'org.apache.flink.api.common.io.compression'

上级 695bc56a
......@@ -15,26 +15,27 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.flink.api.common.io.compression;
import org.apache.flink.annotation.Internal;
import org.apache.commons.compress.compressors.bzip2.BZip2CompressorInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.util.Collection;
import java.util.Collections;
import org.apache.commons.compress.compressors.bzip2.BZip2CompressorInputStream;
/**
* Factory for Bzip2 decompressors.
*/
@Internal
public class Bzip2InputStreamFactory implements InflaterInputStreamFactory<BZip2CompressorInputStream> {
private static Bzip2InputStreamFactory INSTANCE = null;
private static final Bzip2InputStreamFactory INSTANCE = new Bzip2InputStreamFactory();
public static Bzip2InputStreamFactory getInstance() {
if (INSTANCE == null) {
INSTANCE = new Bzip2InputStreamFactory();
}
return INSTANCE;
}
......
......@@ -15,6 +15,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.flink.api.common.io.compression;
import org.apache.flink.annotation.Internal;
......@@ -31,12 +32,9 @@ import java.util.zip.InflaterInputStream;
@Internal
public class DeflateInflaterInputStreamFactory implements InflaterInputStreamFactory<InflaterInputStream> {
private static DeflateInflaterInputStreamFactory INSTANCE = null;
private static final DeflateInflaterInputStreamFactory INSTANCE = new DeflateInflaterInputStreamFactory();
public static DeflateInflaterInputStreamFactory getInstance() {
if (INSTANCE == null) {
INSTANCE = new DeflateInflaterInputStreamFactory();
}
return INSTANCE;
}
......
......@@ -15,6 +15,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.flink.api.common.io.compression;
import org.apache.flink.annotation.Internal;
......@@ -31,14 +32,12 @@ import java.util.zip.GZIPInputStream;
@Internal
public class GzipInflaterInputStreamFactory implements InflaterInputStreamFactory<GZIPInputStream> {
private static GzipInflaterInputStreamFactory INSTANCE = null;
private static final GzipInflaterInputStreamFactory INSTANCE = new GzipInflaterInputStreamFactory();
public static GzipInflaterInputStreamFactory getInstance() {
if (INSTANCE == null) {
INSTANCE = new GzipInflaterInputStreamFactory();
}
return INSTANCE;
}
@Override
public GZIPInputStream create(InputStream in) throws IOException {
return new GZIPInputStream(in);
......
......@@ -15,25 +15,27 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.flink.api.common.io.compression;
import org.apache.commons.compress.compressors.xz.XZCompressorInputStream;
import org.apache.flink.annotation.Internal;
import org.apache.commons.compress.compressors.xz.XZCompressorInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.util.Collection;
import java.util.Collections;
/**
* Factory for XZ decompressors.
*/
@Internal
public class XZInputStreamFactory implements InflaterInputStreamFactory<XZCompressorInputStream> {
private static XZInputStreamFactory INSTANCE = null;
private static final XZInputStreamFactory INSTANCE = new XZInputStreamFactory();
public static XZInputStreamFactory getInstance() {
if (INSTANCE == null) {
INSTANCE = new XZInputStreamFactory();
}
return INSTANCE;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册