Tools.h++ Manual
104011 Tandem Computers Incorporated 21-207
21
RWWString(RWSize_T ic)
Creates a string of length zero (the null string). The strings capacity (that is, the 
size it can grow to without resizing) is given by the parameter 
ic
.
RWWString(const RWWString& str)
;
Copy constructor. The created string will copy 
str 
’s data.
RWWString(const RWWSubString& ss)
;
Conversion from sub-string. The created string will copy the substring 
represented by 
ss
.
RWWString(char c);
Constructs a string containing the single character 
c
.
RWWString(char c, size_t N)
;
Constructs a string containing the character 
c 
repeated 
N 
times.
RWWString(const wchar_t* mbcs, multiByte_ mb);
Construct a wide character string from the multibyte character string contained 
in 
mbcs
. The conversion is done using the Standard C library function 
::mbstowcs()
. This constructor can be used as follows:
RWWString a(“\306\374\315\313\306\374”, multiByte);
RWWString(const wchar_t* acs, ascii_ asc);
Construct a wide character string from the ASCII character string contained in 
acs
. The conversion is done by simply stripping the high-order bit and, hence, 
is much faster than the more general constructor given immediately above. 
For this conversion to be successful, you must be certain that the string 
contains only ASCII characters. This can be confirmed (if necessary) using 
RWCString::isAscii()
. This constructor can be used as follows:
RWWString a(“An ASCII charater string”, ascii);
RWWString(const wchar_t* cs, size_t N, multiByte_ mb);
RWWString(const wchar_t* cs, size_t N, ascii__ asc);
These two constructors are similar to the two constructors immediately above 
except that they copy exactly 
N 
characters, including any embedded nulls. Hence, 
the buffer pointed to by 
cs 
must be at least 
N 
bytes long.
Type conversion
operator const wchar_t*() const
;
Access to the 
RWWString
’s data as a null terminated string. This datum is 
owned by the 
RWWString 
and may not be deleted or changed. If the 
RWWString 
object itself changes or goes out of scope, the pointer value 










