Sign in Join
FPDoc Onlineexperiment

TUnicodeStringBuilder class

In unit sysutils

Ansi-string version of string builder.

Declaration

pascal
TUnicodeStringBuilder = class

Description

TUnicodeStringBuilder is a class to construct an ansistring out of other strings or characters. It's methods can be used instead of constructing the string manually using the normal + or concat operators. If used properly (e.g. by setting a sufficiently large Capacity), will result in faster operation. It offers various methods to append to the string.

To create a unicode string, use the TUnicodeStringBuilder class instead.

See also

Properties

CharspublicIndexed access to the characters in the string.
LengthpublicCurrentl length of the string buffer.
CapacitypublicCurrent capacity of the string buffer.
MaxCapacitypublicMaximum capacity of the string buffer.

Methods

CheckRangeprotected
CheckNegativeprotected
DoAppendprotected
DoInsertprotected
DoReplaceprotected
Growprotected
Shrinkprotected
CreatepublicCreate a new TUnicodeStringBuilder instance.
AppendpublicAppend data in string form to the buffer.
AppendFormatpublicAppend the result of a Format.
AppendLinepublicAppend a string followed by a newline.
ClearpublicClear the string being built.
CopyTopublicCopy string bytes to an array.
EnsureCapacitypublicSet the capacity if needed.
EqualspublicCheck if 2 stringbuilders have the same content string.
GetEnumeratorpublic
InsertpublicInsert data in string form into the buffer at a given position.
RemovepublicRemove data from the string.
ReplacepublicReplace a range of characters.
ToStringpublicReturn the string buffer as an UnicodeString.

Fields

FDataprotected
FLengthprotected
FMaxCapacityprotected

An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.