mina-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From trus...@apache.org
Subject svn commit: r546353 - /mina/trunk/core/src/main/java/org/apache/mina/common/ByteBuffer.java
Date Tue, 12 Jun 2007 01:49:09 GMT
Author: trustin
Date: Mon Jun 11 18:49:09 2007
New Revision: 546353

URL: http://svn.apache.org/viewvc?view=rev&rev=546353
Log:
Removed unnecessary cast

Modified:
    mina/trunk/core/src/main/java/org/apache/mina/common/ByteBuffer.java

Modified: mina/trunk/core/src/main/java/org/apache/mina/common/ByteBuffer.java
URL: http://svn.apache.org/viewvc/mina/trunk/core/src/main/java/org/apache/mina/common/ByteBuffer.java?view=diff&rev=546353&r1=546352&r2=546353
==============================================================================
--- mina/trunk/core/src/main/java/org/apache/mina/common/ByteBuffer.java (original)
+++ mina/trunk/core/src/main/java/org/apache/mina/common/ByteBuffer.java Mon Jun 11 18:49:09
2007
@@ -2041,7 +2041,7 @@
      * @return the EnumSet representation of the bit vector
      */
     public <E extends Enum<E>> EnumSet<E> getEnumSet(Class<E> enumClass)
{
-        return toEnumSet(enumClass, (long) get() & BYTE_MASK);
+        return toEnumSet(enumClass, get() & BYTE_MASK);
     }
 
     /**
@@ -2053,7 +2053,7 @@
      * @return the EnumSet representation of the bit vector
      */
     public <E extends Enum<E>> EnumSet<E> getEnumSetShort(Class<E>
enumClass) {
-        return toEnumSet(enumClass, ((long) getShort()) & SHORT_MASK);
+        return toEnumSet(enumClass, getShort() & SHORT_MASK);
     }
 
     /**
@@ -2065,7 +2065,7 @@
      * @return the EnumSet representation of the bit vector
      */
     public <E extends Enum<E>> EnumSet<E> getEnumSetInt(Class<E>
enumClass) {
-        return toEnumSet(enumClass, (long) getInt() & INT_MASK);
+        return toEnumSet(enumClass, getInt() & INT_MASK);
     }
 
     /**



Mime
View raw message