You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ibatis.apache.org by gb...@apache.org on 2006/03/16 19:20:54 UTC

svn commit: r386407 - /ibatis/trunk/cs/mapper/IBatisNet.Common/Utilities/Objects/ILPropertyAccessor.cs

Author: gbayon
Date: Thu Mar 16 10:20:42 2006
New Revision: 386407

URL: http://svn.apache.org/viewcvs?rev=386407&view=rev
Log:
- Improved enum support in ILPropertyAccessor

Modified:
    ibatis/trunk/cs/mapper/IBatisNet.Common/Utilities/Objects/ILPropertyAccessor.cs

Modified: ibatis/trunk/cs/mapper/IBatisNet.Common/Utilities/Objects/ILPropertyAccessor.cs
URL: http://svn.apache.org/viewcvs/ibatis/trunk/cs/mapper/IBatisNet.Common/Utilities/Objects/ILPropertyAccessor.cs?rev=386407&r1=386406&r2=386407&view=diff
==============================================================================
--- ibatis/trunk/cs/mapper/IBatisNet.Common/Utilities/Objects/ILPropertyAccessor.cs (original)
+++ ibatis/trunk/cs/mapper/IBatisNet.Common/Utilities/Objects/ILPropertyAccessor.cs Thu Mar 16 10:20:42 2006
@@ -131,7 +131,10 @@
         {
             if (type.IsValueType)
             {
-                if (type.IsEnum) { return 0; }
+                if (type.IsEnum) 
+				{ 
+					return GetNullInternal(  Enum.GetUnderlyingType(type) );
+				}
 
                 if (type.IsPrimitive)
                 {