FELIX-948 : Remove casts to integer.

git-svn-id: https://svn.apache.org/repos/asf/felix/trunk@745582 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/framework/src/main/java/org/apache/felix/framework/ServiceRegistrationImpl.java b/framework/src/main/java/org/apache/felix/framework/ServiceRegistrationImpl.java
index 1d46ba2..ddc7451 100644
--- a/framework/src/main/java/org/apache/felix/framework/ServiceRegistrationImpl.java
+++ b/framework/src/main/java/org/apache/felix/framework/ServiceRegistrationImpl.java
@@ -320,11 +320,11 @@
             return null;
         }
     }
-    
+
     class ServiceReferenceImpl implements ServiceReference
     {
         private ServiceReferenceImpl() {}
-    
+
         ServiceRegistrationImpl getServiceRegistration()
         {
             return ServiceRegistrationImpl.this;
@@ -406,7 +406,7 @@
             // Get package wiring from service provider.
             IModule providerModule = ((BundleImpl) m_bundle).getCurrentModule();
             IWire providerWire = Util.getWire(providerModule, pkgName);
-            
+
             // Case 2: Only include service reference if the service
             // object uses the same class as the requester.
             if (providerWire == null)
@@ -461,8 +461,8 @@
                 return 0; // same service
             }
 
-            Object rankObj = (Integer) getProperty(Constants.SERVICE_RANKING);
-            Object otherRankObj = (Integer) other.getProperty(Constants.SERVICE_RANKING);
+            Object rankObj = getProperty(Constants.SERVICE_RANKING);
+            Object otherRankObj = other.getProperty(Constants.SERVICE_RANKING);
 
             // If no rank, then spec says it defaults to zero.
             rankObj = (rankObj == null) ? new Integer(0) : rankObj;