Changeset 39277 in vbox for trunk/include/iprt/cpp
- Timestamp:
- Nov 11, 2011 4:22:46 PM (13 years ago)
- svn:sync-xref-src-repo-rev:
- 74827
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/iprt/cpp/ministring.h
r36532 r39277 826 826 */ 827 827 RTCList<RTCString, RTCString *> split(const RTCString &a_rstrSep, 828 SplitMode a_enmMode = RemoveEmptyParts) ;828 SplitMode a_enmMode = RemoveEmptyParts) const; 829 829 830 830 /** … … 953 953 RTDECL(const RTCString) operator+(const char *a_psz1, const RTCString &a_rstr2); 954 954 955 /** 956 * Class with RTCString::printf as constructor for your convenience. 957 * 958 * Constructing a RTCString string object from a format string and a variable 959 * number of arguments can easily be confused with the other RTCString 960 * constructors, thus this child class. 961 * 962 * The usage of this class is like the following: 963 * @code 964 RTCStringFmt strName("program name = %s", argv[0]); 965 @endcode 966 */ 967 class RTCStringFmt : public RTCString 968 { 969 public: 970 971 /** 972 * Constructs a new string given the format string and the list of the 973 * arguments for the format string. 974 * 975 * @param a_pszFormat Pointer to the format string (UTF-8), 976 * @see pg_rt_str_format. 977 * @param ... Ellipsis containing the arguments specified by 978 * the format string. 979 */ 980 explicit RTCStringFmt(const char *a_pszFormat, ...) 981 { 982 va_list va; 983 va_start(va, a_pszFormat); 984 printfV(a_pszFormat, va); 985 va_end(va); 986 } 987 988 RTMEMEF_NEW_AND_DELETE_OPERATORS(); 989 990 protected: 991 RTCStringFmt() {} 992 }; 993 955 994 /** @} */ 956 995
Note:
See TracChangeset
for help on using the changeset viewer.