Logo Search packages:      
Sourcecode: pwlib version File versions  Download package

BOOL PString::SetSize ( PINDEX  newSize  )  [virtual, inherited]

Set the size of the string. A new string may be allocated to accomodate the new number of characters. If the string increases in size then the new characters are initialised to zero. If the string is made smaller then the data beyond the new size is lost.

Note that this function will break the current instance from multiple references to an array. A new array is allocated and the data from the old array copied to it.

TRUE if the memory for the array was allocated successfully.
newSize  New size of the array in elements.

Definition at line 1639 of file contain.cxx.

Referenced by PFTPClient::GetDirectoryNames(), PString::MakeEmpty(), PString::MakeMinimumSize(), PString::operator &(), PString::operator &=(), PString::operator+(), PString::operator+=(), PString::PString(), PString::ReadFrom(), PChannel::ReadString(), PString::Splice(), and PString::vsprintf().

  return InternalSetSize(newSize, TRUE);

Generated by  Doxygen 1.6.0   Back to index