commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject svn commit: r922388 - in /commons/proper/sanselan/trunk/src/main/java/org/apache/sanselan: common/RationalNumber.java formats/pnm/WhiteSpaceReader.java formats/tiff/photometricinterpreters/PhotometricInterpreterLogLUV.java
Date Fri, 12 Mar 2010 18:47:23 GMT
Author: sebb
Date: Fri Mar 12 18:47:22 2010
New Revision: 922388

URL: http://svn.apache.org/viewvc?rev=922388&view=rev
Log:
Unnecessary casts

Modified:
    commons/proper/sanselan/trunk/src/main/java/org/apache/sanselan/common/RationalNumber.java
    commons/proper/sanselan/trunk/src/main/java/org/apache/sanselan/formats/pnm/WhiteSpaceReader.java
    commons/proper/sanselan/trunk/src/main/java/org/apache/sanselan/formats/tiff/photometricinterpreters/PhotometricInterpreterLogLUV.java

Modified: commons/proper/sanselan/trunk/src/main/java/org/apache/sanselan/common/RationalNumber.java
URL: http://svn.apache.org/viewvc/commons/proper/sanselan/trunk/src/main/java/org/apache/sanselan/common/RationalNumber.java?rev=922388&r1=922387&r2=922388&view=diff
==============================================================================
--- commons/proper/sanselan/trunk/src/main/java/org/apache/sanselan/common/RationalNumber.java
(original)
+++ commons/proper/sanselan/trunk/src/main/java/org/apache/sanselan/common/RationalNumber.java
Fri Mar 12 18:47:22 2010
@@ -91,7 +91,7 @@ public class RationalNumber extends Numb
 
 	public int intValue()
 	{
-		return (int) numerator / (int) divisor;
+		return numerator / divisor;
 	}
 
 	public long longValue()

Modified: commons/proper/sanselan/trunk/src/main/java/org/apache/sanselan/formats/pnm/WhiteSpaceReader.java
URL: http://svn.apache.org/viewvc/commons/proper/sanselan/trunk/src/main/java/org/apache/sanselan/formats/pnm/WhiteSpaceReader.java?rev=922388&r1=922387&r2=922388&view=diff
==============================================================================
--- commons/proper/sanselan/trunk/src/main/java/org/apache/sanselan/formats/pnm/WhiteSpaceReader.java
(original)
+++ commons/proper/sanselan/trunk/src/main/java/org/apache/sanselan/formats/pnm/WhiteSpaceReader.java
Fri Mar 12 18:47:22 2010
@@ -40,13 +40,13 @@ class WhiteSpaceReader
 
 	public char nextChar() throws IOException
 	{
-		char c = (char) read();
+		char c = read();
 
 		if (c == '#')
 		{
 			while ((c != '\n') && (c != '\r'))
 			{
-				c = (char) read();
+				c = read();
 			}
 		}
 		return c;

Modified: commons/proper/sanselan/trunk/src/main/java/org/apache/sanselan/formats/tiff/photometricinterpreters/PhotometricInterpreterLogLUV.java
URL: http://svn.apache.org/viewvc/commons/proper/sanselan/trunk/src/main/java/org/apache/sanselan/formats/tiff/photometricinterpreters/PhotometricInterpreterLogLUV.java?rev=922388&r1=922387&r2=922388&view=diff
==============================================================================
--- commons/proper/sanselan/trunk/src/main/java/org/apache/sanselan/formats/tiff/photometricinterpreters/PhotometricInterpreterLogLUV.java
(original)
+++ commons/proper/sanselan/trunk/src/main/java/org/apache/sanselan/formats/tiff/photometricinterpreters/PhotometricInterpreterLogLUV.java
Fri Mar 12 18:47:22 2010
@@ -139,9 +139,9 @@ public class PhotometricInterpreterLogLU
 		//					R, G, B,
 		//			}, maxRGB, minRGB);
 
-		int red = (int) R;
-		int green = (int) G;
-		int blue = (int) B;
+		int red = R;
+		int green = G;
+		int blue = B;
 
 		red = Math.min(255, Math.max(0, red));
 		green = Math.min(255, Math.max(0, green));



Mime
View raw message