harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sjanu...@apache.org
Subject svn commit: r996798 - in /harmony/enhanced/java/trunk/classlib/modules/pack200/src/main/java/org/apache/harmony: pack200/Archive.java pack200/CpBands.java pack200/Pack200Exception.java unpack200/bytecode/ClassConstantPool.java
Date Tue, 14 Sep 2010 08:55:25 GMT
Author: sjanuary
Date: Tue Sep 14 08:55:24 2010
New Revision: 996798

URL: http://svn.apache.org/viewvc?rev=996798&view=rev
Log:
Code cleanup - remove some unused methods and trailing whitespace

Modified:
    harmony/enhanced/java/trunk/classlib/modules/pack200/src/main/java/org/apache/harmony/pack200/Archive.java
    harmony/enhanced/java/trunk/classlib/modules/pack200/src/main/java/org/apache/harmony/pack200/CpBands.java
    harmony/enhanced/java/trunk/classlib/modules/pack200/src/main/java/org/apache/harmony/pack200/Pack200Exception.java
    harmony/enhanced/java/trunk/classlib/modules/pack200/src/main/java/org/apache/harmony/unpack200/bytecode/ClassConstantPool.java

Modified: harmony/enhanced/java/trunk/classlib/modules/pack200/src/main/java/org/apache/harmony/pack200/Archive.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/java/trunk/classlib/modules/pack200/src/main/java/org/apache/harmony/pack200/Archive.java?rev=996798&r1=996797&r2=996798&view=diff
==============================================================================
--- harmony/enhanced/java/trunk/classlib/modules/pack200/src/main/java/org/apache/harmony/pack200/Archive.java
(original)
+++ harmony/enhanced/java/trunk/classlib/modules/pack200/src/main/java/org/apache/harmony/pack200/Archive.java
Tue Sep 14 08:55:24 2010
@@ -146,7 +146,7 @@ public class Archive {
         List classes = new ArrayList();
         List files = new ArrayList();
         long segmentLimit = options.getSegmentLimit();
-        
+
         int size = packingFileList.size();
         PackingFile packingFile;
         for (int index = 0; index < size; index++) {
@@ -221,9 +221,9 @@ public class Archive {
 
     static class SegmentUnit {
 
-        private List classList;
+        private final List classList;
 
-        private List fileList;
+        private final List fileList;
 
         private int byteAmount = 0;
 
@@ -323,6 +323,10 @@ public class Archive {
         public boolean isDirectory(){
             return isDirectory;
         }
+
+        public String toString() {
+            return name;
+        }
     }
 
 }

Modified: harmony/enhanced/java/trunk/classlib/modules/pack200/src/main/java/org/apache/harmony/pack200/CpBands.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/java/trunk/classlib/modules/pack200/src/main/java/org/apache/harmony/pack200/CpBands.java?rev=996798&r1=996797&r2=996798&view=diff
==============================================================================
--- harmony/enhanced/java/trunk/classlib/modules/pack200/src/main/java/org/apache/harmony/pack200/CpBands.java
(original)
+++ harmony/enhanced/java/trunk/classlib/modules/pack200/src/main/java/org/apache/harmony/pack200/CpBands.java
Tue Sep 14 08:55:24 2010
@@ -151,28 +151,28 @@ public class CpBands extends BandSet {
                 cpUtf8BigChars[i][j] = ((Character) bigChars.remove(0)).charValue();
             }
         }
-        
+
         byte[] encodedBand = encodeBandInt("cpUtf8Prefix", cpUtf8Prefix, Codec.DELTA5);
         out.write(encodedBand);
         PackingUtils.log("Wrote " + encodedBand.length
                 + " bytes from cpUtf8Prefix[" + cpUtf8Prefix.length + "]");
-        
+
         encodedBand = encodeBandInt("cpUtf8Suffix", cpUtf8Suffix, Codec.UNSIGNED5);
         out.write(encodedBand);
         PackingUtils.log("Wrote " + encodedBand.length
                 + " bytes from cpUtf8Suffix[" + cpUtf8Suffix.length + "]");
-        
+
         encodedBand = encodeBandInt("cpUtf8Chars", cpUtf8Chars, Codec.CHAR3);
         out.write(encodedBand);
         PackingUtils.log("Wrote " + encodedBand.length
                 + " bytes from cpUtf8Chars[" + cpUtf8Chars.length + "]");
-        
+
         encodedBand = encodeBandInt("cpUtf8BigSuffix", cpUtf8BigSuffix,
                 Codec.DELTA5);
         out.write(encodedBand);
         PackingUtils.log("Wrote " + encodedBand.length
                 + " bytes from cpUtf8BigSuffix[" + cpUtf8BigSuffix.length + "]");
-        
+
         for (int i = 0; i < cpUtf8BigChars.length; i++) {
             encodedBand = encodeBandInt("cpUtf8BigChars " + i,
                     cpUtf8BigChars[i], Codec.DELTA5);
@@ -238,7 +238,7 @@ public class CpBands extends BandSet {
         out.write(encodedBand);
         PackingUtils.log("Wrote " + encodedBand.length
                 + " bytes from cp_Long_hi[" + highBits.length + "]");
-        
+
         encodedBand = encodeBandInt("cp_Long_lo", loBits, Codec.DELTA5);
         out.write(encodedBand);
         PackingUtils.log("Wrote " + encodedBand.length
@@ -262,7 +262,7 @@ public class CpBands extends BandSet {
         out.write(encodedBand);
         PackingUtils.log("Wrote " + encodedBand.length
                 + " bytes from cp_Double_hi[" + highBits.length + "]");
-        
+
         encodedBand = encodeBandInt("cp_Double_lo", loBits, Codec.DELTA5);
         out.write(encodedBand);
         PackingUtils.log("Wrote " + encodedBand.length
@@ -317,13 +317,13 @@ public class CpBands extends BandSet {
         for (int j = 0; j < cpSignatureClasses.length; j++) {
             cpSignatureClasses[j] = ((CPClass) classes.get(j)).getIndex();
         }
-        
+
         byte[] encodedBand = encodeBandInt("cpSignatureForm", cpSignatureForm,
                 Codec.DELTA5);
         out.write(encodedBand);
         PackingUtils.log("Wrote " + encodedBand.length
                 + " bytes from cpSignatureForm[" + cpSignatureForm.length + "]");
-        
+
         encodedBand = encodeBandInt("cpSignatureClasses", cpSignatureClasses,
                 Codec.UDELTA5);
         out.write(encodedBand);

Modified: harmony/enhanced/java/trunk/classlib/modules/pack200/src/main/java/org/apache/harmony/pack200/Pack200Exception.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/java/trunk/classlib/modules/pack200/src/main/java/org/apache/harmony/pack200/Pack200Exception.java?rev=996798&r1=996797&r2=996798&view=diff
==============================================================================
--- harmony/enhanced/java/trunk/classlib/modules/pack200/src/main/java/org/apache/harmony/pack200/Pack200Exception.java
(original)
+++ harmony/enhanced/java/trunk/classlib/modules/pack200/src/main/java/org/apache/harmony/pack200/Pack200Exception.java
Tue Sep 14 08:55:24 2010
@@ -33,26 +33,4 @@ public class Pack200Exception extends Ex
         super(message);
     }
 
-    /**
-     * Create a new Pack200 exception with the given message and cause
-     *
-     * @param message
-     *            the text message to display
-     * @param cause
-     *            the {@link Throwable} that caused this problem
-     */
-    public Pack200Exception(String message, Throwable cause) {
-        super(message, cause);
-    }
-
-    /**
-     * Create a new Pack200 exception with the given cause
-     *
-     * @param cause
-     *            the {@link Throwable} that caused this problem
-     */
-    public Pack200Exception(Throwable cause) {
-        super(cause);
-    }
-
 }

Modified: harmony/enhanced/java/trunk/classlib/modules/pack200/src/main/java/org/apache/harmony/unpack200/bytecode/ClassConstantPool.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/java/trunk/classlib/modules/pack200/src/main/java/org/apache/harmony/unpack200/bytecode/ClassConstantPool.java?rev=996798&r1=996797&r2=996798&view=diff
==============================================================================
--- harmony/enhanced/java/trunk/classlib/modules/pack200/src/main/java/org/apache/harmony/unpack200/bytecode/ClassConstantPool.java
(original)
+++ harmony/enhanced/java/trunk/classlib/modules/pack200/src/main/java/org/apache/harmony/unpack200/bytecode/ClassConstantPool.java
Tue Sep 14 08:55:24 2010
@@ -115,8 +115,6 @@ public class ClassConstantPool {
             // children now become parents
             parents.clear();
             parents.addAll(children);
-
-
         }
     }
 



Mime
View raw message