svn commit: r980982 - in /ofbiz/trunk/framework/base/src/org/ofbiz/base/util: Assert.java TimeDuration.java

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

svn commit: r980982 - in /ofbiz/trunk/framework/base/src/org/ofbiz/base/util: Assert.java TimeDuration.java

adrianc
Author: adrianc
Date: Fri Jul 30 22:13:48 2010
New Revision: 980982

URL: http://svn.apache.org/viewvc?rev=980982&view=rev
Log:
Documentation improvements in Assert.java and TimeDuration.java. No functional change.

Modified:
    ofbiz/trunk/framework/base/src/org/ofbiz/base/util/Assert.java
    ofbiz/trunk/framework/base/src/org/ofbiz/base/util/TimeDuration.java

Modified: ofbiz/trunk/framework/base/src/org/ofbiz/base/util/Assert.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/base/src/org/ofbiz/base/util/Assert.java?rev=980982&r1=980981&r2=980982&view=diff
==============================================================================
--- ofbiz/trunk/framework/base/src/org/ofbiz/base/util/Assert.java (original)
+++ ofbiz/trunk/framework/base/src/org/ofbiz/base/util/Assert.java Fri Jul 30 22:13:48 2010
@@ -20,9 +20,14 @@ package org.ofbiz.base.util;
 import java.util.Collection;
 import java.util.Map;
 
-/** Basic assertions.
+import org.ofbiz.base.lang.ThreadSafe;
+
+/** Basic assertions. The static methods in this class provide a convenient way
+ * to test method arguments. All of the methods in this class throw <code>
+ * IllegalArgumentException</code> if the method arguments are invalid.
  *
  */
+@ThreadSafe
 public class Assert {
 
     /**
@@ -58,7 +63,7 @@ public class Assert {
     }
 
     /**
-     * Tests if an argument is not null and is an instance of a specified class.
+     * Tests if an argument is not null and is an instance of one of the specified classes.
      * <p><code>Assert.isInstanceOf("foo", foo, Foo.class, Bar.class, ...);</code></p>
      *
      * @param argumentName
@@ -101,7 +106,7 @@ public class Assert {
     }
 
     /**
-     * Tests if an argument is not null and is not an instance of a specified class.
+     * Tests if an argument is not null and is not an instance of one of the specified classes.
      * <p><code>Assert.isNotInstanceOf("foo", foo, Foo.class, Bar.class, ...);</code></p>
      *
      * @param argumentName

Modified: ofbiz/trunk/framework/base/src/org/ofbiz/base/util/TimeDuration.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/base/src/org/ofbiz/base/util/TimeDuration.java?rev=980982&r1=980981&r2=980982&view=diff
==============================================================================
--- ofbiz/trunk/framework/base/src/org/ofbiz/base/util/TimeDuration.java (original)
+++ ofbiz/trunk/framework/base/src/org/ofbiz/base/util/TimeDuration.java Fri Jul 30 22:13:48 2010
@@ -19,12 +19,15 @@
 package org.ofbiz.base.util;
 
 import java.io.Serializable;
-import com.ibm.icu.util.Calendar;
 
 import org.ofbiz.base.lang.SourceMonitored;
+import org.ofbiz.base.lang.ThreadSafe;
+
+import com.ibm.icu.util.Calendar;
 
 /** An immutable representation of a period of time. */
 @SourceMonitored
+@ThreadSafe
 @SuppressWarnings("serial")
 public class TimeDuration implements Serializable, Comparable<TimeDuration> {
     /** A <code>TimeDuration</code> instance that represents a zero time duration. */