From 87159c55214223be8142904ae1ba0bd027a452e9 Mon Sep 17 00:00:00 2001 From: Rodrigo Alves Vieira Date: Sat, 4 May 2013 18:40:02 -0300 Subject: [PATCH] Small tweaks in the br.ufpe.cin.groundhog.extractor module. Related to #20. --- .../br/ufpe/cin/groundhog/extractor/DefaultUncompressor.java | 5 +++++ src/java/main/br/ufpe/cin/groundhog/extractor/Extractor.java | 1 - src/java/main/br/ufpe/cin/groundhog/extractor/Type.java | 5 +++++ .../main/br/ufpe/cin/groundhog/extractor/Uncompressor.java | 1 - .../br/ufpe/cin/groundhog/extractor/ZipUncompressor.java | 3 +-- 5 files changed, 11 insertions(+), 4 deletions(-) diff --git a/src/java/main/br/ufpe/cin/groundhog/extractor/DefaultUncompressor.java b/src/java/main/br/ufpe/cin/groundhog/extractor/DefaultUncompressor.java index cff15bd..5228813 100644 --- a/src/java/main/br/ufpe/cin/groundhog/extractor/DefaultUncompressor.java +++ b/src/java/main/br/ufpe/cin/groundhog/extractor/DefaultUncompressor.java @@ -10,6 +10,11 @@ import org.apache.commons.compress.compressors.bzip2.BZip2CompressorInputStream; +/** + * The default file uncompressor in Groundhog + * @author fjsj + * + */ public class DefaultUncompressor { private static DefaultUncompressor instance; diff --git a/src/java/main/br/ufpe/cin/groundhog/extractor/Extractor.java b/src/java/main/br/ufpe/cin/groundhog/extractor/Extractor.java index 0e0e1d9..0b9e540 100644 --- a/src/java/main/br/ufpe/cin/groundhog/extractor/Extractor.java +++ b/src/java/main/br/ufpe/cin/groundhog/extractor/Extractor.java @@ -4,6 +4,5 @@ public interface Extractor { public void extractFile(File file, File destinationFolder); - public void recursiveExtract(File target, File destinationFolder); } \ No newline at end of file diff --git a/src/java/main/br/ufpe/cin/groundhog/extractor/Type.java b/src/java/main/br/ufpe/cin/groundhog/extractor/Type.java index 878d1de..ec5c9e8 100644 --- a/src/java/main/br/ufpe/cin/groundhog/extractor/Type.java +++ b/src/java/main/br/ufpe/cin/groundhog/extractor/Type.java @@ -1,5 +1,10 @@ package br.ufpe.cin.groundhog.extractor; +/** + * The supported compression types + * @author fjsj + * + */ public enum Type { TAR, RAR, ZIP } \ No newline at end of file diff --git a/src/java/main/br/ufpe/cin/groundhog/extractor/Uncompressor.java b/src/java/main/br/ufpe/cin/groundhog/extractor/Uncompressor.java index c823448..12e6e52 100644 --- a/src/java/main/br/ufpe/cin/groundhog/extractor/Uncompressor.java +++ b/src/java/main/br/ufpe/cin/groundhog/extractor/Uncompressor.java @@ -5,5 +5,4 @@ public interface Uncompressor { public Type getType(); public void uncompress(File file); - } \ No newline at end of file diff --git a/src/java/main/br/ufpe/cin/groundhog/extractor/ZipUncompressor.java b/src/java/main/br/ufpe/cin/groundhog/extractor/ZipUncompressor.java index 0d8fd3a..964a253 100644 --- a/src/java/main/br/ufpe/cin/groundhog/extractor/ZipUncompressor.java +++ b/src/java/main/br/ufpe/cin/groundhog/extractor/ZipUncompressor.java @@ -41,8 +41,7 @@ public static void extract(File zipFile, File dir) throws IOException { ZipEntry entry = (ZipEntry) e.nextElement(); currentFile = new File(dir, entry.getName()); - // if the directory is inexistent, create the structure and jump - // to the next entry + // if the directory is inexistent, create the structure and jump to the next entry if (entry.isDirectory()) { if (!currentFile.exists()) { currentFile.mkdirs();