felix-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From clem...@apache.org
Subject svn commit: r1180386 - /felix/trunk/ipojo/core/src/main/java/org/apache/felix/ipojo/util/Property.java
Date Sat, 08 Oct 2011 15:15:59 GMT
Author: clement
Date: Sat Oct  8 15:15:59 2011
New Revision: 1180386

URL: http://svn.apache.org/viewvc?rev=1180386&view=rev
Log:
Applied the patch from Robert Lillack fixing FELIX-2981.

Modified:
    felix/trunk/ipojo/core/src/main/java/org/apache/felix/ipojo/util/Property.java

Modified: felix/trunk/ipojo/core/src/main/java/org/apache/felix/ipojo/util/Property.java
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/core/src/main/java/org/apache/felix/ipojo/util/Property.java?rev=1180386&r1=1180385&r2=1180386&view=diff
==============================================================================
--- felix/trunk/ipojo/core/src/main/java/org/apache/felix/ipojo/util/Property.java (original)
+++ felix/trunk/ipojo/core/src/main/java/org/apache/felix/ipojo/util/Property.java Sat Oct
 8 15:15:59 2011
@@ -303,10 +303,6 @@ public class Property implements FieldIn
      * @return the default value.
      */
     public Object getDefaultValue() {
-        if (m_defaultValue == NO_VALUE) {
-            return getNoValue(m_type);
-        }
-
         return m_defaultValue;
     }
 
@@ -364,7 +360,7 @@ public class Property implements FieldIn
      * @return <code>true</code> if the object is assignable in the property
of type 'type'.
      */
     public static boolean isAssignable(Class type, Object value) {
-        if (value == null || type.isInstance(value)) { // When the value is null, the assign
works necessary.
+        if (value == null || type.isInstance(value) || value == Property.NO_VALUE) { // When
the value is null, the assign works necessary.
             return true;
         } else if (type.isPrimitive()) {
             // Manage all boxing types.



Mime
View raw message