cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r661415 - in /cxf/branches/2.0.x-fixes: ./ tools/common/src/main/java/org/apache/cxf/tools/common/DataTypeAdapter.java tools/common/src/main/java/org/apache/cxf/tools/common/Messages.properties
Date Thu, 29 May 2008 17:32:29 GMT
Author: dkulp
Date: Thu May 29 10:32:29 2008
New Revision: 661415

URL: http://svn.apache.org/viewvc?rev=661415&view=rev
Log:
Merged revisions 661409,661413 via svnmerge from 
https://svn.apache.org/repos/asf/cxf/trunk

........
  r661409 | dkulp | 2008-05-29 13:23:34 -0400 (Thu, 29 May 2008) | 2 lines
  
  [CXF-1602] Add better fault message 
........
  r661413 | dkulp | 2008-05-29 13:30:29 -0400 (Thu, 29 May 2008) | 2 lines
  
  [CXF-1602] Revert last commit as null is actually valid if the date is a optional attribute.
 Just return null.
........

Modified:
    cxf/branches/2.0.x-fixes/   (props changed)
    cxf/branches/2.0.x-fixes/tools/common/src/main/java/org/apache/cxf/tools/common/DataTypeAdapter.java
    cxf/branches/2.0.x-fixes/tools/common/src/main/java/org/apache/cxf/tools/common/Messages.properties

Propchange: cxf/branches/2.0.x-fixes/
------------------------------------------------------------------------------
Binary property 'svnmerge-integrated' - no diff available.

Modified: cxf/branches/2.0.x-fixes/tools/common/src/main/java/org/apache/cxf/tools/common/DataTypeAdapter.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.0.x-fixes/tools/common/src/main/java/org/apache/cxf/tools/common/DataTypeAdapter.java?rev=661415&r1=661414&r2=661415&view=diff
==============================================================================
--- cxf/branches/2.0.x-fixes/tools/common/src/main/java/org/apache/cxf/tools/common/DataTypeAdapter.java
(original)
+++ cxf/branches/2.0.x-fixes/tools/common/src/main/java/org/apache/cxf/tools/common/DataTypeAdapter.java
Thu May 29 10:32:29 2008
@@ -20,34 +20,54 @@
 
 import java.util.Calendar;
 import java.util.Date;
+
 import javax.xml.bind.DatatypeConverter;
 
 public final class DataTypeAdapter {
+
     private DataTypeAdapter() {
     }
 
     public static Date parseDate(String s) {
+        if (s == null) {
+            return null;
+        }
         return DatatypeConverter.parseDate(s).getTime();
     }
     public static String printDate(Date dt) {
+        if (dt == null) {
+            return null;
+        }
         Calendar c = Calendar.getInstance();
         c.setTime(dt);
         return DatatypeConverter.printDate(c);
     }
 
     public static Date parseTime(String s) {
+        if (s == null) {
+            return null;
+        }
         return DatatypeConverter.parseTime(s).getTime();
     }
     public static String printTime(Date dt) {
+        if (dt == null) {
+            return null;
+        }
         Calendar c = Calendar.getInstance();
         c.setTime(dt);
         return DatatypeConverter.printTime(c);
     }
 
     public static Date parseDateTime(String s) {
+        if (s == null) {
+            return null;
+        }
         return DatatypeConverter.parseDateTime(s).getTime();
     }
     public static String printDateTime(Date dt) {
+        if (dt == null) {
+            return null;
+        }
         Calendar c = Calendar.getInstance();
         c.setTime(dt);
         return DatatypeConverter.printDateTime(c);

Modified: cxf/branches/2.0.x-fixes/tools/common/src/main/java/org/apache/cxf/tools/common/Messages.properties
URL: http://svn.apache.org/viewvc/cxf/branches/2.0.x-fixes/tools/common/src/main/java/org/apache/cxf/tools/common/Messages.properties?rev=661415&r1=661414&r2=661415&view=diff
==============================================================================
--- cxf/branches/2.0.x-fixes/tools/common/src/main/java/org/apache/cxf/tools/common/Messages.properties
(original)
+++ cxf/branches/2.0.x-fixes/tools/common/src/main/java/org/apache/cxf/tools/common/Messages.properties
Thu May 29 10:32:29 2008
@@ -30,3 +30,4 @@
 VELOCITY_ENGINE_WRITE_ERRORS = Velocity engine write errors
 FAIL_TO_WRITE_FILE = Failed to write file: {0}
 FAIL_TO_COMPILE_GENERATE_CODES = Failed to compile generated code
+



Mime
View raw message