]> git.saurik.com Git - apple/icu.git/blobdiff - icuSources/common/util.h
ICU-64252.0.1.tar.gz
[apple/icu.git] / icuSources / common / util.h
index a5841dc95ab2d2b5c54d5c11b0659a089ef96da4..e197cab7882842a14d6fa11b9fb0dd9ca94ddbcb 100644 (file)
@@ -1,12 +1,15 @@
+// © 2016 and later: Unicode, Inc. and others.
+// License & terms of use: http://www.unicode.org/copyright.html
 /*
-**********************************************************************
-*   Copyright (c) 2001-2004, International Business Machines
-*   Corporation and others.  All Rights Reserved.
-**********************************************************************
-*   Date        Name        Description
-*   11/19/2001  aliu        Creation.
-**********************************************************************
-*/
+ **********************************************************************
+ *   Copyright (c) 2001-2011, International Business Machines
+ *   Corporation and others.  All Rights Reserved.
+ **********************************************************************
+ *   Date        Name        Description
+ *   11/19/2001  aliu        Creation.
+ **********************************************************************
+ */
+
 #ifndef ICU_UTIL_H
 #define ICU_UTIL_H
 
@@ -43,6 +46,13 @@ class U_COMMON_API ICU_Utility /* not : public UObject because all methods are s
                                        int32_t radix = 10,
                                        int32_t minDigits = 1);
 
+    /** Returns a bogus UnicodeString by value. */
+    static inline UnicodeString makeBogusString() {
+        UnicodeString result;
+        result.setToBogus();
+        return result;
+    }
+
     /**
      * Return true if the character is NOT printable ASCII.
      *
@@ -88,8 +98,8 @@ class U_COMMON_API ICU_Utility /* not : public UObject because all methods are s
                                   UBool advance = FALSE);
 
     /**
-     * Skip over whitespace in a Replaceable.  Whitespace is defined by
-     * uprv_isRuleWhiteSpace().  Skipping may be done in the forward or
+     * Skip over Pattern_White_Space in a Replaceable.
+     * Skipping may be done in the forward or
      * reverse direction.  In either case, the leftmost index will be
      * inclusive, and the rightmost index will be exclusive.  That is,
      * given a range defined as [start, limit), the call
@@ -149,7 +159,7 @@ class U_COMMON_API ICU_Utility /* not : public UObject because all methods are s
      * pattern.  Characters are matched literally and case-sensitively
      * except for the following special characters:
      *
-     * ~  zero or more uprv_isRuleWhiteSpace chars
+     * ~  zero or more Pattern_White_Space chars
      *
      * If end of pattern is reached with all matches along the way,
      * pos is advanced to the first unparsed index and returned.
@@ -234,12 +244,5 @@ private:
 
 U_NAMESPACE_END
 
-/**
- * Is this character a "white space" in the sense of ICU rule parsers?
- * @internal
- */
-U_CAPI UBool U_EXPORT2
-uprv_isRuleWhiteSpace(UChar32 c);
-
 #endif
 //eof