[jboss-cvs] JBossAS SVN: r90328 - in projects/vfs/trunk/src/main/java/org/jboss/virtual/spi/zip: truezip and 1 other directory.
jboss-cvs-commits at lists.jboss.org
jboss-cvs-commits at lists.jboss.org
Wed Jun 17 09:27:36 EDT 2009
Author: alesj
Date: 2009-06-17 09:27:35 -0400 (Wed, 17 Jun 2009)
New Revision: 90328
Added:
projects/vfs/trunk/src/main/java/org/jboss/virtual/spi/zip/jdk/JDKZipEntryProvider.java
Removed:
projects/vfs/trunk/src/main/java/org/jboss/virtual/spi/zip/jdk/JDKZipProvider.java
Modified:
projects/vfs/trunk/src/main/java/org/jboss/virtual/spi/zip/jdk/JDKZipFactory.java
projects/vfs/trunk/src/main/java/org/jboss/virtual/spi/zip/truezip/TrueZipEntryProvider.java
Log:
Proper class name.
Copied: projects/vfs/trunk/src/main/java/org/jboss/virtual/spi/zip/jdk/JDKZipEntryProvider.java (from rev 90315, projects/vfs/trunk/src/main/java/org/jboss/virtual/spi/zip/jdk/JDKZipProvider.java)
===================================================================
--- projects/vfs/trunk/src/main/java/org/jboss/virtual/spi/zip/jdk/JDKZipEntryProvider.java (rev 0)
+++ projects/vfs/trunk/src/main/java/org/jboss/virtual/spi/zip/jdk/JDKZipEntryProvider.java 2009-06-17 13:27:35 UTC (rev 90328)
@@ -0,0 +1,72 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.virtual.spi.zip.jdk;
+
+import java.io.IOException;
+import java.io.InputStream;
+import java.util.zip.ZipInputStream;
+
+import org.jboss.virtual.spi.zip.ZipEntry;
+import org.jboss.virtual.spi.zip.ZipEntryProvider;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.org">Ales Justin</a>
+ */
+public class JDKZipEntryProvider implements ZipEntryProvider
+{
+ private ZipInputStream zis;
+
+ public JDKZipEntryProvider(ZipInputStream zis)
+ {
+ if (zis == null)
+ throw new IllegalArgumentException("Null Zip input stream.");
+
+ this.zis = zis;
+ }
+
+ public ZipEntry getNextEntry() throws IOException
+ {
+ java.util.zip.ZipEntry entry = zis.getNextEntry();
+ return entry != null ? wrap(entry) : null;
+ }
+
+ /**
+ * Wrap the entry.
+ *
+ * @param entry the entry
+ * @return wrapped entry
+ */
+ protected ZipEntry wrap(java.util.zip.ZipEntry entry)
+ {
+ return new JDKZipEntry(entry);
+ }
+
+ public InputStream currentStream() throws IOException
+ {
+ return new IgnoreCloseInputStream(zis);
+ }
+
+ public void close() throws IOException
+ {
+ zis.close();
+ }
+}
\ No newline at end of file
Modified: projects/vfs/trunk/src/main/java/org/jboss/virtual/spi/zip/jdk/JDKZipFactory.java
===================================================================
--- projects/vfs/trunk/src/main/java/org/jboss/virtual/spi/zip/jdk/JDKZipFactory.java 2009-06-17 13:14:02 UTC (rev 90327)
+++ projects/vfs/trunk/src/main/java/org/jboss/virtual/spi/zip/jdk/JDKZipFactory.java 2009-06-17 13:27:35 UTC (rev 90328)
@@ -38,7 +38,7 @@
public ZipEntryProvider createProvider(InputStream is)
{
ZipInputStream zis = new ZipInputStream(is);
- return new JDKZipProvider(zis);
+ return new JDKZipEntryProvider(zis);
}
public ZipFile createFile(File file) throws IOException
Deleted: projects/vfs/trunk/src/main/java/org/jboss/virtual/spi/zip/jdk/JDKZipProvider.java
===================================================================
--- projects/vfs/trunk/src/main/java/org/jboss/virtual/spi/zip/jdk/JDKZipProvider.java 2009-06-17 13:14:02 UTC (rev 90327)
+++ projects/vfs/trunk/src/main/java/org/jboss/virtual/spi/zip/jdk/JDKZipProvider.java 2009-06-17 13:27:35 UTC (rev 90328)
@@ -1,72 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source.
- * Copyright 2008, Red Hat Middleware LLC, and individual contributors
- * as indicated by the @author tags. See the copyright.txt file in the
- * distribution for a full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.virtual.spi.zip.jdk;
-
-import java.io.IOException;
-import java.io.InputStream;
-import java.util.zip.ZipInputStream;
-
-import org.jboss.virtual.spi.zip.ZipEntry;
-import org.jboss.virtual.spi.zip.ZipEntryProvider;
-
-/**
- * @author <a href="mailto:ales.justin at jboss.org">Ales Justin</a>
- */
-public class JDKZipProvider implements ZipEntryProvider
-{
- private ZipInputStream zis;
-
- public JDKZipProvider(ZipInputStream zis)
- {
- if (zis == null)
- throw new IllegalArgumentException("Null Zip input stream.");
-
- this.zis = zis;
- }
-
- public ZipEntry getNextEntry() throws IOException
- {
- java.util.zip.ZipEntry entry = zis.getNextEntry();
- return entry != null ? wrap(entry) : null;
- }
-
- /**
- * Wrap the entry.
- *
- * @param entry the entry
- * @return wrapped entry
- */
- protected ZipEntry wrap(java.util.zip.ZipEntry entry)
- {
- return new JDKZipEntry(entry);
- }
-
- public InputStream currentStream() throws IOException
- {
- return new IgnoreCloseInputStream(zis);
- }
-
- public void close() throws IOException
- {
- zis.close();
- }
-}
\ No newline at end of file
Modified: projects/vfs/trunk/src/main/java/org/jboss/virtual/spi/zip/truezip/TrueZipEntryProvider.java
===================================================================
--- projects/vfs/trunk/src/main/java/org/jboss/virtual/spi/zip/truezip/TrueZipEntryProvider.java 2009-06-17 13:14:02 UTC (rev 90327)
+++ projects/vfs/trunk/src/main/java/org/jboss/virtual/spi/zip/truezip/TrueZipEntryProvider.java 2009-06-17 13:27:35 UTC (rev 90328)
@@ -23,13 +23,13 @@
import java.util.zip.ZipInputStream;
-import org.jboss.virtual.spi.zip.jdk.JDKZipProvider;
+import org.jboss.virtual.spi.zip.jdk.JDKZipEntryProvider;
import org.jboss.virtual.spi.zip.ZipEntry;
/**
* @author <a href="mailto:ales.justin at jboss.org">Ales Justin</a>
*/
-public class TrueZipEntryProvider extends JDKZipProvider
+public class TrueZipEntryProvider extends JDKZipEntryProvider
{
public TrueZipEntryProvider(ZipInputStream zis)
{
More information about the jboss-cvs-commits
mailing list