You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by gg...@apache.org on 2022/11/30 12:09:49 UTC

[commons-compress] branch master updated (1b712dcc -> e38d4b88)

This is an automated email from the ASF dual-hosted git repository.

ggregory pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/commons-compress.git


    from 1b712dcc Fix spelling
     new ab7a7626 Use Javadoc format
     new e38d4b88 Make private final a static and upper name

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../commons/compress/harmony/unpack200/AttributeLayoutMap.java   | 9 +++++----
 .../commons/compress/harmony/unpack200/bytecode/ClassFile.java   | 5 +++--
 2 files changed, 8 insertions(+), 6 deletions(-)


[commons-compress] 01/02: Use Javadoc format

Posted by gg...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

ggregory pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-compress.git

commit ab7a76263db14978e2b6f4160739dc35f186b920
Author: Gary Gregory <ga...@gmail.com>
AuthorDate: Wed Nov 30 07:07:25 2022 -0500

    Use Javadoc format
---
 .../commons/compress/harmony/unpack200/AttributeLayoutMap.java   | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/src/main/java/org/apache/commons/compress/harmony/unpack200/AttributeLayoutMap.java b/src/main/java/org/apache/commons/compress/harmony/unpack200/AttributeLayoutMap.java
index 4c2d6ed4..ae838e92 100644
--- a/src/main/java/org/apache/commons/compress/harmony/unpack200/AttributeLayoutMap.java
+++ b/src/main/java/org/apache/commons/compress/harmony/unpack200/AttributeLayoutMap.java
@@ -125,10 +125,11 @@ public class AttributeLayoutMap {
     private final Map<Integer, AttributeLayout> methodLayouts = new HashMap<>();
     private final Map<Integer, AttributeLayout> codeLayouts = new HashMap<>();
 
-    // The order of the maps in this array should not be changed as their
-    // indices correspond to
-    // the value of their context constants (AttributeLayout.CONTEXT_CLASS etc.)
-	private final Map[] layouts = { classLayouts, fieldLayouts, methodLayouts, codeLayouts };
+    /**
+     * The order of the maps in this array should not be changed as their indices correspond to the value of their context constants
+     * (AttributeLayout.CONTEXT_CLASS etc.)
+     */
+    private final Map[] layouts = { classLayouts, fieldLayouts, methodLayouts, codeLayouts };
 
     private final Map<AttributeLayout, NewAttributeBands> layoutsToBands = new HashMap<>();
 


[commons-compress] 02/02: Make private final a static and upper name

Posted by gg...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

ggregory pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-compress.git

commit e38d4b88faa6541d0c45d2418898f2c45589e041
Author: Gary Gregory <ga...@gmail.com>
AuthorDate: Wed Nov 30 07:09:44 2022 -0500

    Make private final a static and upper name
---
 .../commons/compress/harmony/unpack200/bytecode/ClassFile.java       | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/src/main/java/org/apache/commons/compress/harmony/unpack200/bytecode/ClassFile.java b/src/main/java/org/apache/commons/compress/harmony/unpack200/bytecode/ClassFile.java
index 6f4426dc..031a83ad 100644
--- a/src/main/java/org/apache/commons/compress/harmony/unpack200/bytecode/ClassFile.java
+++ b/src/main/java/org/apache/commons/compress/harmony/unpack200/bytecode/ClassFile.java
@@ -24,9 +24,10 @@ import java.io.IOException;
  */
 public class ClassFile {
 
+    private static final int MAGIC = 0xCAFEBABE;
+
     public int major;
     public int minor;
-    private final int magic = 0xCAFEBABE;
     public ClassConstantPool pool = new ClassConstantPool();
     public int accessFlags;
     public int thisClass;
@@ -37,7 +38,7 @@ public class ClassFile {
     public Attribute[] attributes;
 
     public void write(final DataOutputStream dos) throws IOException {
-        dos.writeInt(magic);
+        dos.writeInt(MAGIC);
         dos.writeShort(minor);
         dos.writeShort(major);
         dos.writeShort(pool.size() + 1);