From b3995e25c2bb044c2ce6edb79c593a32b4e4b2c9 Mon Sep 17 00:00:00 2001 From: cbpporter Date: Fri, 14 Nov 2008 20:18:06 +0000 Subject: [PATCH] Documentation updates git-svn-id: svn://ultimatepp.org/upp/trunk@636 f0d560ea-af0d-0410-9eb7-867de7ffcac7 --- uppsrc/Core/src.tpp/DateFmt$en-us.tpp | 43 +- uppsrc/Core/src.tpp/Exc$en-us.tpp | 3 +- uppsrc/Core/src.tpp/Format$en-us.tpp | 10 +- uppsrc/Core/src.tpp/FormatFn$en-us.tpp | 234 +++--- uppsrc/Core/src.tpp/NetNode$en-us.tpp | 54 +- uppsrc/Core/src.tpp/String$en-us.tpp | 990 ++++++++++++++---------- uppsrc/Core/src.tpp/VectorMap$en-us.tpp | 79 +- 7 files changed, 805 insertions(+), 608 deletions(-) diff --git a/uppsrc/Core/src.tpp/DateFmt$en-us.tpp b/uppsrc/Core/src.tpp/DateFmt$en-us.tpp index 683961569..a0148e868 100644 --- a/uppsrc/Core/src.tpp/DateFmt$en-us.tpp +++ b/uppsrc/Core/src.tpp/DateFmt$en-us.tpp @@ -10,11 +10,12 @@ topic "Date formatting and scanning"; [i448;b42;O9;2 $$8,8#61672508125594000341940100500538:tparam] [b42;2 $$9,9#13035079074754324216151401829390:normal] [{_}%EN-US -[s0;%- Date formatting and scanning&] -[s0;3 &] -[s5;K%- [@(0.0.255) const][@(64) _][@(0.0.255) char][@(64) _`*]StrToDate[@(64) (][^`:`:Date^@(64) D -ate][@(64) `&_][@3 d][@(64) , ][@(0.0.255) const][@(64) _][@(0.0.255) char][@(64) _`*][@3 s][@(64) ) -]&] +[s0;%- [*@3;4 Date formatting and scanning]&] +[s0; &] +[ {{10000F(128)G(128)@1 [s0; [* Global functions]]}}&] +[s0;%- &] +[s5;:StrToDate`(Date`&`,const char`*`):%- [@(0.0.255) const]_[@(0.0.255) char]_`*[* StrToDa +te]([_^Date^ Date][@(0.0.255) `&]_[*@3 d], [@(0.0.255) const]_[@(0.0.255) char]_`*[*@3 s])&] [s2; Scans a string for a Date. Order of day, month and year is specified using SetDateScan. In place of month both number and text is accepted `- text must match abbreviated or full name of month.&] @@ -22,33 +23,39 @@ accepted `- text must match abbreviated or full name of month.&] [s7; [%-*C@3 s]-|String to scan.&] [s7; [*/ Return value]-|NULL if no date is found in s or position right after the date.&] -[s0;3 &] -[s5;K%- [^`:`:String^ String]_Format[@(64) (][^`:`:Date^@(64) Date][@(64) _][@3 date][@(64) )]&] +[s3; &] +[s4;%- &] +[s5;:Format`(Date`):%- [_^String^ String]_[* Format]([_^Date^ Date]_[*@3 date])&] [s2; Formats date. Date is formated using the standard Format function, where the string set by SetDateFormat is used as formating string, and the three supplied integer value arguments are year, month and day.&] [s7; [%-*C@3 date]-|Date to format.&] [s7; [*/ Return value]-|Formatted date.&] -[s0;3 &] -[s5;K%- [@(0.0.255) int][@(64) _]CharFilterDate[@(64) (][@(0.0.255) int][@(64) _][@3 c][@(64) )]&] +[s3; &] +[s4;%- &] +[s5;:CharFilterDate`(int`):%- [@(0.0.255) int]_[* CharFilterDate]([@(0.0.255) int]_[*@3 c])&] [s2; Character filter for dates. Its behaviour is specified by SetDateFilter function.&] [s7; [%-*C@3 c]-|Character to filter.&] [s7; [*/ Return value]-|Filtered character.&] -[s0; &] -[s0;%- void_[* SetDateFormat](const_char_`*[*@3 fmt])&] +[s3; &] +[s4;%- &] +[s5;:SetDateFormat`(const char`*`):%- [@(0.0.255) void]_[* SetDateFormat]([@(0.0.255) const +]_[@(0.0.255) char]_`*[*@3 fmt])&] [s2; Sets formating string for dates.&] [s7; [%-*C@3 fmt]-|Formating string.&] -[s0;3 &] -[s5;K%- [@(0.0.255) void][@(64) _]SetDateScan[@(64) (][@(0.0.255) const][@(64) _][@(0.0.255) char -][@(64) _`*][@3 scan][@(64) )]&] +[s3; &] +[s4;%- &] +[s5;:SetDateScan`(const char`*`):%- [@(0.0.255) void]_[* SetDateScan]([@(0.0.255) const]_[@(0.0.255) c +har]_`*[*@3 scan])&] [s2; Sets date scan string `- this string represents order of day, month and year for StrToDate function.&] [s7; [%-*C@3 scan]-|Date scan string.&] -[s0;3 &] -[s5;K%- [@(0.0.255) void][@(64) _]SetDateFilter[@(64) (][@(0.0.255) const][@(64) _][@(0.0.255) ch -ar][@(64) _`*][@3 seps][@(64) )]&] +[s3; &] +[s4;%- &] +[s5;:SetDateFilter`(const char`*`):%- [@(0.0.255) void]_[* SetDateFilter]([@(0.0.255) const +]_[@(0.0.255) char]_`*[*@3 seps])&] [s2; Specifies CharFilterDate behaviour. Digits are always allowed in CharFilterDate. If there is `"a`" at the beginning of seps string, letters are allowed. If there is `"A`", letters are allowed @@ -57,5 +64,5 @@ list of characters allowed as separator follows. `"`\a`" after character designates `"amend`" character `- if used, all characters up to next `"amend`" character are replaced by it.&] [s7; [%-*C@3 seps]-|Filter`-string.&] -[s0;3 &] +[s1; &] [s0; ] \ No newline at end of file diff --git a/uppsrc/Core/src.tpp/Exc$en-us.tpp b/uppsrc/Core/src.tpp/Exc$en-us.tpp index e22f29ead..1cec2f873 100644 --- a/uppsrc/Core/src.tpp/Exc$en-us.tpp +++ b/uppsrc/Core/src.tpp/Exc$en-us.tpp @@ -11,8 +11,7 @@ topic "Miscellaneous"; [b42;2 $$9,9#13035079074754324216151401829390:normal] [{_}%EN-US [s1; [*@3;4 Exc]&] -[s0; &] -[s1;:Exc`:`:class:%- [@(0.0.255)3 class][3 _][*3 Exc][3 _:_][@(0.0.255)3 public][3 _][*@3;3 String]&] +[s0;%- [@(0.0.255)3 class][3 _][*3 Exc][3 _:_][@(0.0.255)3 public][3 _][*@3;3 String]&] [s0; &] [s0; This is the preferred root class of U`+`+ exception. It is basically a String. The idea is that all kinds of exception can be either diff --git a/uppsrc/Core/src.tpp/Format$en-us.tpp b/uppsrc/Core/src.tpp/Format$en-us.tpp index a47d7bfe2..b4059f896 100644 --- a/uppsrc/Core/src.tpp/Format$en-us.tpp +++ b/uppsrc/Core/src.tpp/Format$en-us.tpp @@ -10,7 +10,7 @@ topic "Text formatting"; [i448;b42;O9;2 $$8,8#61672508125594000341940100500538:tparam] [b42;2 $$9,9#13035079074754324216151401829390:normal] [{_}%EN-US -[s0; [*4 Format `- text formatting]&] +[s0; [*@3;4 Format `- text formatting]&] [s0;*+117 &] [s5;:`:`:Format`(const char`*`,const`:`:Vector`<`:`:Value`>`&`):%- [^`:`:String^ String ]_[* Format][@(64) (][@(0.0.255) const][@(64) _][@(0.0.255) char][@(64) _`*][*@3 format][@(64) , @@ -345,12 +345,13 @@ width&] ][^Formatting^@(64) Formatting][@(64) `&_fmt)]&] [s2; Formatter has to have form of function with single [^Formatting^ Formatting] argument.&] -[s3; &] +[s1; &] [ {{10000F(128)G(128)@1 [s0; [* Formatting]]}}&] -[s4;%- &] +[s0;%- &] [s1;:Formatting`:`:struct:%- [@(0.0.255) struct]_[* Formatting]&] [s2; This structure passes all informations to format Value argument to the formatter.&] +[s3; &] [s4;%- &] [s5;:Formatting`:`:language:%- [@(0.0.255) int]_[* language]&] [s2; Language of resulting text.&] @@ -366,7 +367,7 @@ to the formatter.&] [s4;%- &] [s5;:Formatting`:`:id:%- String_[* id]&] [s2; Formatter`-id.&] -[s3; &] +[s1; &] [ {{10000F(128)G(128)@1 [s0; [* Format registration functions]]}}&] [s3;%- &] [s5;:RegisterFormatter`(int`,const char`*`,Formatter`)init`_:%- [@(0.0.255) void]_[* Regi @@ -407,4 +408,5 @@ terNullFormatter]([@(0.0.255) const]_[@(0.0.255) char]_`*[*@3 id], Formatter_[*@3 f])&] [s2; Registers formatter [%-*@3 id] to be applied when the Value argument is Void (Value()) or ErrorValue.&] +[s1; &] [s0; ] \ No newline at end of file diff --git a/uppsrc/Core/src.tpp/FormatFn$en-us.tpp b/uppsrc/Core/src.tpp/FormatFn$en-us.tpp index 77684a0b4..1eb1291b0 100644 --- a/uppsrc/Core/src.tpp/FormatFn$en-us.tpp +++ b/uppsrc/Core/src.tpp/FormatFn$en-us.tpp @@ -1,123 +1,128 @@ topic "Formatting functions"; -[ $$0,0#00000000000000000000000000000000:Default] -[l288;2 $$1,0#27521748481378242620020725143825:desc] -[H6;0 $$2,0#05600065144404261032431302351956:begin] -[i448;a25;kKO9;2 $$3,0#37138531426314131252341829483370:item] -[0 $$4,0#96390100711032703541132217272105:end] +[2 $$0,0#00000000000000000000000000000000:Default] +[i448;a25;kKO9;2 $$1,0#37138531426314131252341829483380:class] +[l288;2 $$2,0#27521748481378242620020725143825:desc] +[0 $$3,0#96390100711032703541132217272105:end] +[H6;0 $$4,0#05600065144404261032431302351956:begin] +[i448;a25;kKO9;2 $$5,0#37138531426314131252341829483370:item] +[l288;a4;*@5;1 $$6,6#70004532496200323422659154056402:requirement] +[l288;i1121;b17;O9;~~~.1408;2 $$7,0#10431211400427159095818037425705:param] +[i448;b42;O9;2 $$8,8#61672508125594000341940100500538:tparam] +[b42;2 $$9,9#13035079074754324216151401829390:normal] [{_}%EN-US -[s0; [*4 Formatting functions]&] +[s0; [*@3;4 Formatting functions]&] [s0; &] [ {{10000F(128)G(128)@1 [s0; [* Global functions]]}}&] -[s2;H0;%- &] -[s3;:FormatInt`(int`):%- [_^String^ String]_[* FormatInt]([@(0.0.255) int]_[*@3 i])&] -[s1; Outputs decimally formatted signed integer [%-*@3 i] without `+ +[s4;H0;%- &] +[s5;:FormatInt`(int`):%- [_^String^ String]_[* FormatInt]([@(0.0.255) int]_[*@3 i])&] +[s2; Outputs decimally formatted signed integer [%-*@3 i] without `+ or any paddings. Supposed to be quite fast. Equivalent to FormatIntBase(i, 10).&] -[s4;* &] -[s2;%- &] -[s3;:FormatIntDec`(int`,int`,char`,bool`):%- [_^String^ String]_[* FormatIntDec]([@(0.0.255) i +[s3;* &] +[s4;%- &] +[s5;:FormatIntDec`(int`,int`,char`,bool`):%- [_^String^ String]_[* FormatIntDec]([@(0.0.255) i nt]_[*@3 i], [@(0.0.255) int]_[*@3 width], [@(0.0.255) char]_[*@3 lpad]_`=_`'_`', [@(0.0.255) bool]_[*@3 always`_sign]_`=_[@(0.0.255) false])&] -[s1; Formats a signed decimal integer [%-*@3 i] with left padding up +[s2; Formats a signed decimal integer [%-*@3 i] with left padding up to given [%-*@3 width] characters (output longer than this is not padded) with a given [%-*@3 lpad] character. If [%-*@3 always`_sign ]is true, start positive numbers with `'`+`' (negative numbers always start with `'`-`').&] -[s4; &] -[s2;%- &] -[s3;:FormatIntHex`(int`,int`,char`):%- [_^String^ String]_[* FormatIntHex]([@(0.0.255) int]_ +[s3; &] +[s4;%- &] +[s5;:FormatIntHex`(int`,int`,char`):%- [_^String^ String]_[* FormatIntHex]([@(0.0.255) int]_ [*@3 i], [@(0.0.255) int]_[*@3 width]_`=_[@3 8], [@(0.0.255) char]_[*@3 lpad]_`=_`'[@3 0]`')&] -[s1;~~~.1152; Formats an unsigned hexadecimal (radix 16) integer +[s2;~~~.1152; Formats an unsigned hexadecimal (radix 16) integer [%-*@3 i] with left padding up to given [%-*@3 width] characters (output longer than this is not padded) with a given [%-*@3 lpad] character.&] -[s4; &] -[s2;%- &] -[s3;:FormatIntOct`(int`,int`,char`):%- [_^String^ String]_[* FormatIntOct]([@(0.0.255) int]_ +[s3; &] +[s4;%- &] +[s5;:FormatIntOct`(int`,int`,char`):%- [_^String^ String]_[* FormatIntOct]([@(0.0.255) int]_ [*@3 i], [@(0.0.255) int]_[*@3 width]_`=_[@3 12], [@(0.0.255) char]_[*@3 lpad]_`=_`'[@3 0]`')&] -[s1; Formats an unsigned octal (radix 8) integer [%-*@3 i] with left +[s2; Formats an unsigned octal (radix 8) integer [%-*@3 i] with left padding up to given [%-*@3 width] characters (output longer than this is not padded) with a given [%-*@3 lpad] character.&] -[s4; &] -[s2;%- &] -[s3;:FormatIntRoman`(int`,bool`):%- [_^String^ String]_[* FormatIntRoman]([@(0.0.255) int]_ +[s3; &] +[s4;%- &] +[s5;:FormatIntRoman`(int`,bool`):%- [_^String^ String]_[* FormatIntRoman]([@(0.0.255) int]_ [*@3 i], [@(0.0.255) bool]_[*@3 upper]_`=_[@(0.0.255) false])&] -[s1; Formats a signed integer [%-*@3 i] in Roman numerals. The biggest +[s2; Formats a signed integer [%-*@3 i] in Roman numerals. The biggest `"implemented`" numeral is M (1000), so expect quite a long return string when formatting a billion. Negative numbers are prepended with `[`-`], 0 or Null is output as a Null String. If [%-*@3 upper] is true, use uppercase `[true`] or lowercase `[false`] letters&] -[s4; &] -[s2;%- &] -[s3;:FormatIntAlpha`(int`,bool`):%- [_^String^ String]_[* FormatIntAlpha]([@(0.0.255) int]_ +[s3; &] +[s4;%- &] +[s5;:FormatIntAlpha`(int`,bool`):%- [_^String^ String]_[* FormatIntAlpha]([@(0.0.255) int]_ [*@3 i], [@(0.0.255) bool]_[*@3 upper]_`=_[@(0.0.255) true])&] -[s1; Formats a signed integer [%-*@3 i] in length`-first lexicographic +[s2; Formats a signed integer [%-*@3 i] in length`-first lexicographic index, i.e. excel column numbering (1 `= A,2 `= B.. 26 `= Z, 27 `= AA, 28 `= AB .. 52 `= AZ, 53 `= BA ... 78 `= BZ etc). 0 or Null is output as a Null String. Only negative numbers are prepended with a `[`-`]. If [%-*@3 upper] is true, use uppercase letter.&] -[s4; &] -[s2;%- &] -[s3;:Format64`(uint64`):%- [_^String^ String]_[* Format64]([_^uint64^ uint64]_[*@3 a])&] -[s1; Formats an unsigned decimal 64`-bit integer [%-*@3 a]. Supposed +[s3; &] +[s4;%- &] +[s5;:Format64`(uint64`):%- [_^String^ String]_[* Format64]([_^uint64^ uint64]_[*@3 a])&] +[s2; Formats an unsigned decimal 64`-bit integer [%-*@3 a]. Supposed to be quite fast.&] -[s4; &] -[s2;%- &] -[s3;:Format64Hex`(uint64`):%- [_^String^ String]_[* Format64Hex]([_^uint64^ uint64]_[*@3 a])&] -[s1; Formats an unsigned hexadecimal [%-*@3 a] (radix 16) 64`-bit integer. +[s3; &] +[s4;%- &] +[s5;:Format64Hex`(uint64`):%- [_^String^ String]_[* Format64Hex]([_^uint64^ uint64]_[*@3 a])&] +[s2; Formats an unsigned hexadecimal [%-*@3 a] (radix 16) 64`-bit integer. Supposed to be quite fast. Lowecase letters a`-f are used for digits `[10`] through `[15`].&] -[s4; &] -[s2;%- &] -[s3;:FormatIntHex`(const void`*`):%- [_^String^ String]_[* FormatIntHex]([@(0.0.255) const]_ +[s3; &] +[s4;%- &] +[s5;:FormatIntHex`(const void`*`):%- [_^String^ String]_[* FormatIntHex]([@(0.0.255) const]_ [@(0.0.255) void]_`*[*@3 ptr])&] -[s1; Formats the pointer address [%-*@3 ptr] as a hexadecimal (base +[s2; Formats the pointer address [%-*@3 ptr] as a hexadecimal (base 16) number zero`-padded to the number of digits appropriate for the memory model (8 digits in 32`-bit systems, 16 digits in 64`-bit systems). Useful for logging and debugging purposes. Equivalent to FormatHex, god knows why there are two of them.&] -[s4; &] -[s2;%- &] -[s3;:FormatHex`(const void`*`):%- [_^String^ String]_[* FormatHex]([@(0.0.255) const]_[@(0.0.255) v +[s3; &] +[s4;%- &] +[s5;:FormatHex`(const void`*`):%- [_^String^ String]_[* FormatHex]([@(0.0.255) const]_[@(0.0.255) v oid]_`*[*@3 ptr])&] -[s1; Same as FormatIntHex.&] -[s4; &] -[s2;%- &] -[s3;:FormatInteger`(int`):%- [_^String^ String]_[* FormatInteger]([@(0.0.255) int]_[*@3 a])&] -[s1; Formats a signed decimal integer without padding. In comparison +[s2; Same as FormatIntHex.&] +[s3; &] +[s4;%- &] +[s5;:FormatInteger`(int`):%- [_^String^ String]_[* FormatInteger]([@(0.0.255) int]_[*@3 a])&] +[s2; Formats a signed decimal integer without padding. In comparison to FormatInt it returns String(Null) when given int(Null) whereas FormatInt returns a plain empty string.&] -[s4; &] -[s2;%- &] -[s3;:FormatUnsigned`(unsigned long`):%- [_^String^ String]_[* FormatUnsigned]([@(0.0.255) u +[s3; &] +[s4;%- &] +[s5;:FormatUnsigned`(unsigned long`):%- [_^String^ String]_[* FormatUnsigned]([@(0.0.255) u nsigned]_[@(0.0.255) long]_[*@3 a])&] -[s1; A very old freak, implemented through Sprintf(`"%u`", a). Deprecated.&] -[s4; &] -[s2;%- &] -[s3;:FormatDouble`(double`):%- [_^String^ String]_[* FormatDouble]([@(0.0.255) double]_[*@3 a +[s2; A very old freak, implemented through Sprintf(`"%u`", a). Deprecated.&] +[s3; &] +[s4;%- &] +[s5;:FormatDouble`(double`):%- [_^String^ String]_[* FormatDouble]([@(0.0.255) double]_[*@3 a ])&] -[s1; Formats a floating point [%-*@3 a] in decimal notation automatically +[s2; Formats a floating point [%-*@3 a] in decimal notation automatically selecting ordinary or scientific (exponential) notation according to the absolute value of a. In ordinary notation, the number is formatted to 10 significant digits; in exponential notation, the mantissa is formatted to 10 decimal digits.&] -[s4; &] -[s2;%- &] -[s3;:FormatBool`(bool`):%- [_^String^ String]_[* FormatBool]([@(0.0.255) bool]_[*@3 a])&] -[s1; Formats a boolean [%-*@3 a] as one of the fixed words `"true`" +[s3; &] +[s4;%- &] +[s5;:FormatBool`(bool`):%- [_^String^ String]_[* FormatBool]([@(0.0.255) bool]_[*@3 a])&] +[s2; Formats a boolean [%-*@3 a] as one of the fixed words `"true`" or `"false`" (regardless of language settings).&] -[s4; &] -[s2;%- &] -[s3;:FormatInt64`(int64`):%- [_^String^ String]_[* FormatInt64]([_^int64^ int64]_[*@3 a])&] -[s1; Formats a signed decimal 64`-bit integer [%-*@3 a] without any +[s3; &] +[s4;%- &] +[s5;:FormatInt64`(int64`):%- [_^String^ String]_[* FormatInt64]([_^int64^ int64]_[*@3 a])&] +[s2; Formats a signed decimal 64`-bit integer [%-*@3 a] without any padding. Only negative numbers are prepended with a `[`-`].&] -[s4; &] -[s2;%- &] -[s3;:FormatDouble`(double`,int`,int`,int`):%- [_^String^ String]_[* FormatDouble]([@(0.0.255) d +[s3; &] +[s4;%- &] +[s5;:FormatDouble`(double`,int`,int`,int`):%- [_^String^ String]_[* FormatDouble]([@(0.0.255) d ouble]_[*@3 d], [@(0.0.255) int]_[*@3 digits], [@(0.0.255) int]_[*@3 flags]_`=_[@3 0], [@(0.0.255) int]_[*@3 fill`_exp]_`=_[@3 0])&] -[s1; Formats a floating point number [%-*@3 d] in decimal notation +[s2; Formats a floating point number [%-*@3 d] in decimal notation automatically selecting ordinary or scientific (exponential) notation according to the absolute value of a and the given number of [%-*@3 digits]. In the (default) absolute decimal mode, a number @@ -128,68 +133,69 @@ notation whenever its absolute value exceeds the interval `[10`^`-<2 `* digits>, 10`^`+<2 `* digits>`]. [%-*@3 flags] can be a binary combination ([@(0.0.255) `|]) of&] [s0; &] -[ {{2098:7902<288;h1; [s0; [2 FD`_SIGN]] -:: [s0; [/2 always prepend sign (`+10)]] -:: [s0; [2 FD`_REL]] -:: [s0; [/2 relative decimal places (valid digits)]] -:: [s0; [2 FD`_SIGN`_EXP]] -:: [s0; [/2 always prepend sign to exponent (1e`+2)]] -:: [s0; [2 FD`_CAP`_E]] -:: [s0; [/2 capital E for exponent (1E10)]] -:: [s0; [2 FD`_ZERO]] -:: [s0; [/2 keep trailing zeros (1.25000)]] -:: [s0; [2 FD`_FIX]] -:: [s0; [/2 always use fixed notation (FormatDouble only)]] -:: [s0; [2 FD`_EXP]] -:: [s0; [/2 always use exponential notation (FormatDouble only)]]}}&] -[s1; &] -[s1; [*@3 fill`_exp ]is left zero`-padding of exponent in exponential +[ {{2098:7902<288;h1; [s0; FD`_SIGN] +:: [s0; [/ always prepend sign (`+10)]] +:: [s0; FD`_REL] +:: [s0; [/ relative decimal places (valid digits)]] +:: [s0; FD`_SIGN`_EXP] +:: [s0; [/ always prepend sign to exponent (1e`+2)]] +:: [s0; FD`_CAP`_E] +:: [s0; [/ capital E for exponent (1E10)]] +:: [s0; FD`_ZERO] +:: [s0; [/ keep trailing zeros (1.25000)]] +:: [s0; FD`_FIX] +:: [s0; [/ always use fixed notation (FormatDouble only)]] +:: [s0; FD`_EXP] +:: [s0; [/ always use exponential notation (FormatDouble only)]]}}&] +[s2; &] +[s2; [*@3 fill`_exp ]is left zero`-padding of exponent in exponential notation&] -[s4; &] -[s2;%- &] -[s3;:FormatDoubleFix`(double`,int`,int`):%- [_^String^ String]_[* FormatDoubleFix]([@(0.0.255) d +[s3; &] +[s4;%- &] +[s5;:FormatDoubleFix`(double`,int`,int`):%- [_^String^ String]_[* FormatDoubleFix]([@(0.0.255) d ouble]_[*@3 d], [@(0.0.255) int]_[*@3 digits], [@(0.0.255) int]_[*@3 flags]_`=_[@3 0])&] -[s1; Formats a floating point number [%-*@3 d] in ordinary decimal +[s2; Formats a floating point number [%-*@3 d] in ordinary decimal notation (whole part, comma, decimal part). Then number of [%-*@3 digits] can be interpreted either as the absolute number of decimal digits (the default mode) or the relative number of significant digits excluding leading zeros. Decimal point is always output as a period independent on language settings. [%-*@3 flags] can be a binary combination ([@(0.0.255) `|]) of&] -[ {{2098:7902<288;h1; [s0; [2 FD`_SIGN]] -:: [s0; [/2 always prepend sign (`+10)]] -:: [s0; [2 FD`_REL]] -:: [s0; [/2 relative decimal places (valid digits)]] -:: [s0; [2 FD`_ZERO]] -:: [s0; [/2 keep trailing zeros (1.25000)]]}}&] -[s4; &] -[s2;%- &] -[s3;:FormatDoubleExp`(double`,int`,int`,int`):%- [_^String^ String]_[* FormatDoubleExp]([@(0.0.255) d +[ {{2098:7902<288;h1; [s0; FD`_SIGN] +:: [s0; [/ always prepend sign (`+10)]] +:: [s0; FD`_REL] +:: [s0; [/ relative decimal places (valid digits)]] +:: [s0; FD`_ZERO] +:: [s0; [/ keep trailing zeros (1.25000)]]}}&] +[s3; &] +[s4;%- &] +[s5;:FormatDoubleExp`(double`,int`,int`,int`):%- [_^String^ String]_[* FormatDoubleExp]([@(0.0.255) d ouble]_[*@3 d], [@(0.0.255) int]_[*@3 digits], [@(0.0.255) int]_[*@3 flags]_`=_[@3 0], [@(0.0.255) int]_[*@3 fill`_exp]_`=_[@3 0])&] -[s1; Formats a floating point number [%-*@3 d] in scientific / exponential +[s2; Formats a floating point number [%-*@3 d] in scientific / exponential notation (sign, single digit, period, decimal part, `"e`" decimal exponent) with given number of [%-*@3 digits]. [%-*@3 flags] can be a binary combination ([@(0.0.255) `|]) of&] -[s1; &] -[ {{2098:7902<288;h1; [s0; [2 FD`_SIGN]] -:: [s0; [/2 always prepend sign (`+10)]] -:: [s0; [2 FD`_SIGN`_EXP]] -:: [s0; [/2 always prepend sign to exponent (1e`+2)]] -:: [s0; [2 FD`_CAP`_E]] -:: [s0; [/2 capital E for exponent (1E10)]] -:: [s0; [2 FD`_ZERO]] -:: [s0; [/2 keep trailing zeros (1.25000)]]}}&] -[s1; &] -[s1; [*@3 fill`_exp ]is left zero`-padding of exponent in exponential +[s2; &] +[ {{2098:7902<288;h1; [s0; FD`_SIGN] +:: [s0; [/ always prepend sign (`+10)]] +:: [s0; FD`_SIGN`_EXP] +:: [s0; [/ always prepend sign to exponent (1e`+2)]] +:: [s0; FD`_CAP`_E] +:: [s0; [/ capital E for exponent (1E10)]] +:: [s0; FD`_ZERO] +:: [s0; [/ keep trailing zeros (1.25000)]]}}&] +[s2; &] +[s2; [*@3 fill`_exp ]is left zero`-padding of exponent in exponential notation&] -[s4; &] -[s2;%- &] -[s3;:FormatIntBase`(int`,int`,int`,char`,int`):%- [_^String^ String]_[* FormatIntBase]([@(0.0.255) i +[s3; &] +[s4;%- &] +[s5;:FormatIntBase`(int`,int`,int`,char`,int`):%- [_^String^ String]_[* FormatIntBase]([@(0.0.255) i nt]_[*@3 i], [@(0.0.255) int]_[*@3 base], [@(0.0.255) int]_[*@3 width]_`=_[@3 0], [@(0.0.255) char]_[*@3 lpad]_`=_`'_`', [@(0.0.255) int]_[*@3 sign]_`=_[@3 0])&] -[s1; Formats a signed or unsigned integer [%-*@3 i] in a given radix +[s2; Formats a signed or unsigned integer [%-*@3 i] in a given radix [%-*@3 base] with left padding to given [%-*@3 width] with a given [%-*@3 lpad] character. If [*@3 sign ]is `+1 `= always prepend `'`+`'/`-, if 0 `= auto (`'`-`' only), if `-1, format as unsigned.&] +[s1; &] [s0; ] \ No newline at end of file diff --git a/uppsrc/Core/src.tpp/NetNode$en-us.tpp b/uppsrc/Core/src.tpp/NetNode$en-us.tpp index bcaeaa9fa..f853e1a9e 100644 --- a/uppsrc/Core/src.tpp/NetNode$en-us.tpp +++ b/uppsrc/Core/src.tpp/NetNode$en-us.tpp @@ -10,53 +10,55 @@ topic "NetNode"; [i448;b42;O9;2 $$8,8#61672508125594000341940100500538:tparam] [b42;2 $$9,9#13035079074754324216151401829390:normal] [{_} -[s0; [@(0.0.255) class]_[* NetNode]_:_[@(0.0.255) private]_[*@3 Moveable][@(0.0.255) <][* NetNode][@(0.0.255) > -]_&] -[s2;%% &] -[s2;%% This class represents single network node (network resource). +[s0; [*@3;4 NetNode]&] +[s1;:NetNode`:`:class: [@(0.0.255)3 class][3 _][*3 NetNode][3 _:_][@(0.0.255)3 private][3 _][*@3;3 M +oveable][@(0.0.255)3 <][*3 NetNode][@(0.0.255)3 >][3 _]&] +[s6;l0;%% WIN32 specific&] +[s6;l0;%% &] +[s0;%% This class represents single network node (network resource). It is [^topic`:`/`/Core`/srcdoc`/Moveable`$en`-us^ moveable] and has deep copy.&] -[s0;%% &] +[s1;%% &] +[ {{10000F(128)G(128)@1 [s0;%% [* Constructor Detail]]}}&] +[s0; &] +[s5;:NetNode`:`:NetNode`(`): [* NetNode]()&] +[s2;%% Default constructor.&] [s3; &] [s4; &] -[s5;:`:`:NetNode`:`:GetName`(`)const: [_^`:`:String^ String]_[* GetName]()_[@(0.0.255) cons -t]&] +[s5;:NetNode`:`:NetNode`(const NetNode`&`): [* NetNode]([@(0.0.255) const]_[* NetNode][@(0.0.255) `& +]_[*@3 s])&] +[s2;%% Deep copy constructor.&] +[s1;%% &] +[ {{10000F(128)G(128)@1 [s0;%% [* Public Member List]]}}&] +[s0; &] +[s5;:NetNode`:`:GetName`(`)const: [_^String^ String]_[* GetName]()_[@(0.0.255) const]&] [s2;%% Returns the name of network node (e.g. for displaying in GUI).&] [s3; &] [s4; &] -[s5;:`:`:NetNode`:`:GetPath`(`)const: [_^`:`:String^ String]_[* GetPath]()_[@(0.0.255) cons -t]&] +[s5;:NetNode`:`:GetPath`(`)const: [_^String^ String]_[* GetPath]()_[@(0.0.255) const]&] [s2;%% If node represents a disk share, it returns a path to this share (like `\`\SERVER`\DATA). FindFile can be used to retrieve the list of files on this path (you have to add a file mask). If this method returns empty String, node is not a disk share.&] [s3; &] [s4; &] -[s5;:`:`:NetNode`:`:Enum`(`)const: [_^`:`:Array^ Array][@(0.0.255) <][_^`:`:NetNode^ NetNod -e][@(0.0.255) >]_[* Enum]()_[@(0.0.255) const]&] +[s5;:NetNode`:`:Enum`(`)const: [_^Array^ Array][@(0.0.255) <][_^NetNode^ NetNode][@(0.0.255) > +]_[* Enum]()_[@(0.0.255) const]&] [s2;%% Returns the array of subnodes.&] [s3; &] [s4; &] -[s5;:`:`:NetNode`:`:Serialize`(`:`:Stream`&`): [@(0.0.255) void]_[* Serialize]([_^`:`:Stream^ S -tream][@(0.0.255) `&]_[*@3 s])&] +[s5;:NetNode`:`:Serialize`(Stream`&`): [@(0.0.255) void]_[* Serialize]([_^Stream^ Stream][@(0.0.255) `& +]_[*@3 s])&] [s2;%% Serializes the Node.&] [s3; &] [s4; &] -[s5;:`:`:NetNode`:`:EnumRoot`(`): [@(0.0.255) static] [_^`:`:Array^ Array][@(0.0.255) <][_^`:`:NetNode^ N +[s5;:NetNode`:`:EnumRoot`(`): [@(0.0.255) static] [_^Array^ Array][@(0.0.255) <][_^NetNode^ N etNode][@(0.0.255) >]_[* EnumRoot]()&] [s2;%% Enumerates root nodes.&] [s3; &] [s4; &] -[s5;:`:`:NetNode`:`:NetNode`(`): [* NetNode]()&] -[s2;%% Default constructor.&] -[s3; &] -[s4; &] -[s5;:`:`:NetNode`:`:NetNode`(const`:`:NetNode`&`): [* NetNode]([@(0.0.255) const]_[* NetNod -e][@(0.0.255) `&]_[*@3 s])&] -[s2;%% Deep copy constructor.&] -[s3; &] -[s4; &] -[s5;:`:`:NetNode`:`:operator`=`(const`:`:NetNode`&`): [_^`:`:NetNode^ NetNode][@(0.0.255) `& -]_[* operator`=]([@(0.0.255) const]_[_^`:`:NetNode^ NetNode][@(0.0.255) `&]_[*@3 s])&] +[s5;:NetNode`:`:operator`=`(const NetNode`&`): [_^NetNode^ NetNode][@(0.0.255) `&]_[* opera +tor`=]([@(0.0.255) const]_[_^NetNode^ NetNode][@(0.0.255) `&]_[*@3 s])&] [s2;%% Deep copy assignment.&] -[s0;%% ] \ No newline at end of file +[s1; &] +[s0; ] \ No newline at end of file diff --git a/uppsrc/Core/src.tpp/String$en-us.tpp b/uppsrc/Core/src.tpp/String$en-us.tpp index fcc798b3c..27b07b31e 100644 --- a/uppsrc/Core/src.tpp/String$en-us.tpp +++ b/uppsrc/Core/src.tpp/String$en-us.tpp @@ -9,451 +9,623 @@ topic "[W]String and [W]StringBuffer"; [l288;i1121;b17;O9;~~~.1408;2 $$7,0#10431211400427159095818037425705:param] [i448;b42;O9;2 $$8,8#61672508125594000341940100500538:tparam] [b42;2 $$9,9#13035079074754324216151401829390:normal] -[{_}%EN-US -[s0; `[W`]String and `[W`]StringBuffer&] -[s0; `[W`]String is a value class that contains an array of characters -(or bytes in case of String). It is designed to have fast copy -operations. The array of characters is zero terminated. String -provides non`-mutable access to the array of characters. String -variant stores 8 bit characters (or bytes), whereas WString is -storing 16 bit unicode characters.&] +[{_} +[s0;%% [*@3;4 String]&] +[s1;:String`:`:class: [@(0.0.255)3 class][3 _][*3 String][3 _:_][@(0.0.255)3 public][3 _][*@3;3 Move +able][@(0.0.255)3 <][*3 String][3 , ][_^AString^3 AString][@(0.0.255)3 <][_^String0^3 String0 +][@(0.0.255)3 >][3 _>_]&] +[s0;3 &] +[s0;%% String is a value class that contains an array of characters. +It is designed to have fast copy operations. The array of characters +is zero terminated. String provides non`-mutable access to the +array of characters. String can store 8 bit encoded string or +an Utf8 encoded string&] +[s0;%% &] +[s0;%% WString is similar to String, but it uses 16 bit Ucs2 encoding. +String and WString share a number of common functions through +the AString interface.&] +[s1;%% &] +[ {{10000F(128)G(128)@1 [s0;%% [* Constructor Detail]]}}&] [s0; &] -[s0; StringBuffer is a class related to String that serves as mutable -buffer.&] -[s0;@(0.0.255) &] -[s0;@(0.0.255) &] -[s0;%- [*+117 `[W`]String common methods]&] -[s0;@(0.0.255) &] -[s5;K:`:`:AString`:`:Remove`(int`,int`):%- [@(0.0.255) void][@(64) _]Remove[@(64) (][@(0.0.255) i -nt][@(64) _][@3 at][@(64) , ][@(0.0.255) int][@(64) _][@3 count][@(64) _`=_][@3 1][@(64) )]&] -[s2; Removes [%-*@3 count] element starting at position [%-*@3 at].&] +[s5;:String`:`:String`(`): [* String]()&] +[s2;%% Default constructor. Constructs empty String.&] +[s3; &] +[s4; &] +[s5;:String`:`:String`(const String`&`): [* String]([@(0.0.255) const]_[* String][@(0.0.255) `& +]_[*@3 s])&] +[s2;%% Default copy constructor..&] +[s3;%% &] +[s4; &] +[s5;:String`:`:String`(const char`*`): [* String]([@(0.0.255) const]_[@(0.0.255) char]_`*[*@3 s +])&] +[s2;%% Creates a copy of zero terminated string [%-*@3 s].&] +[s3;%% &] +[s4; &] +[s5;:String`:`:String`(const char`*`,int`): [* String]([@(0.0.255) const]_[@(0.0.255) char]_ +`*[*@3 s], [@(0.0.255) int]_[*@3 n])&] +[s2;%% Constructs a string equal to first [%-*@3 n] characters of zero +terminated string [%-*@3 s].&] +[s3;%% &] +[s4; &] +[s5;:String`:`:String`(const String`&`,int`): [* String]([@(0.0.255) const]_[* String][@(0.0.255) `& +]_[*@3 s], [@(0.0.255) int]_[*@3 n])&] +[s2;%% Constructs a string equal to first [%-*@3 n] characters of String +[%-*@3 s].&] +[s3;%% &] +[s4; &] +[s5;:String`:`:String`(const byte`*`,int`): [* String]([@(0.0.255) const]_[_^byte^ byte]_`* +[*@3 s], [@(0.0.255) int]_[*@3 n])&] +[s2;%% Constructs a string equal to first [%-*@3 n] bytes of [%-*@3 s].&] +[s3;%% &] +[s4; &] +[s5;:String`:`:String`(const char`*`,const char`*`): [* String]([@(0.0.255) const]_[@(0.0.255) c +har]_`*[*@3 s], [@(0.0.255) const]_[@(0.0.255) char]_`*[*@3 lim])&] +[s2;%% Constructs a string equal to first [%-*@3 lim] `- [%-*@3 s] characters +of [%-*@3 s].&] +[s3;%% &] +[s4; &] +[s5;:String`:`:String`(int`,int`): [* String]([@(0.0.255) int]_[*@3 chr], +[@(0.0.255) int]_[*@3 count])&] +[s2;%% Constructs a string consisting of [%-*@3 count] characters equal +to [%-*@3 chr].&] +[s3;%% &] +[s4; &] +[s5;:String`:`:String`(StringBuffer`&`): [* String]([_^StringBuffer^ StringBuffer][@(0.0.255) `& +]_[*@3 b])&] +[s2;%% Constructs a string from [%-*@3 b]. [%-*@3 b] is emptied by this +operation.&] +[s3;%% &] +[s4; &] +[s5;:String`:`:String`(const Nuller`&`): [* String]([@(0.0.255) const]_[_^Nuller^ Nuller][@(0.0.255) `& +])&] +[s2;%% Constructs empty `[W`]String. This variant is important to +allow assigning Null to String (which is same as assigning the +empty String).&] +[s3; &] +[s4; &] +[s5;:String`:`:String`(const string`&`): [* String]([@(0.0.255) const]_std`::string[@(0.0.255) `& +]_[*@3 s])&] +[s2;%% Constructor to achieve minimal STL compatibility.&] +[s1;%% &] +[ {{10000F(128)G(128)@1 [s0;%% [* Public Member List]]}}&] [s0; &] -[s5;K:`:`:AString`:`:Set`(int`,int`):%- [@(0.0.255) void][@(64) _]Set[@(64) (][@(0.0.255) int -][@(64) _][@3 at][@(64) , ][@(0.0.255) int][@(64) _][@3 chr][@(64) )]&] -[s2; Replace character at position [%-*@3 at] with [%-*@3 chr].&] -[s0; &] -[s5;K:`:`:AString`:`:Trim`(int`):%- [@(0.0.255) void][@(64) _]Trim[@(64) (][@(0.0.255) int][@(64) _ -][@3 at][@(64) )]&] -[s2; Sets the number of characters (length) to [%-*@3 at].&] -[s0; &] -[s5;K:`:`:AString`:`:GetLength`(`)const:%- [@(0.0.255) int][@(64) _]GetLength[@(64) ()_][@(0.0.255) c -onst]&] -[s5;K:`:`:AString`:`:GetCount`(`)const:%- [@(0.0.255) int][@(64) _]GetCount[@(64) ()_][@(0.0.255) c -onst]&] -[s2; Returns the number of characters.&] -[s0; &] -[s5;K:`:`:AString`:`:IsEmpty`(`)const:%- [@(0.0.255) bool][@(64) _]IsEmpty[@(64) ()_][@(0.0.255) c -onst]&] -[s2; Same as GetCount() `=`= 0.&] -[s0; &] -[s5;K:`:`:AString`:`:Find`(int`,int`)const:%- [@(0.0.255) int][@(64) _]Find[@(64) (][@(0.0.255) i -nt][@(64) _][@3 chr][@(64) , ][@(0.0.255) int][@(64) _][@3 from][@(64) _`=_][@3 0][@(64) )_][@(0.0.255) c -onst]&] -[s2; Returns a position of character equal to [%-*@3 chr] greater or -equal to [%-*@3 from], or `-1 if not found.&] -[s0; &] -[s5;K:`:`:AString`:`:ReverseFind`(int`,int`)const:%- [@(0.0.255) int][@(64) _]ReverseFind -[@(64) (][@(0.0.255) int][@(64) _][@3 chr][@(64) , ][@(0.0.255) int][@(64) _][@3 from][@(64) )_][@(0.0.255) c -onst]&] -[s2; Returns a position of [/ last] character equal to [%-*@3 chr] lower -or equal to [%-*@3 from], or `-1 if not found.&] -[s0; &] -[s5;K:`:`:AString`:`:ReverseFind`(int`)const:%- [@(0.0.255) int][@(64) _]ReverseFind[@(64) ( -][@(0.0.255) int][@(64) _][@3 chr][@(64) )_][@(0.0.255) const]&] -[s2; Returns a position of [/ last] character equal to [%-*@3 chr], or -`-1 if not found.&] -[s0; &] -[s5;K:`:`:AString`:`:Find`(int`,const T`*`,int`)const:%- [@(0.0.255) int][@(64) _]Find[@(64) ( -][@(0.0.255) int][@(64) _][@3 len][@(64) , ][@(0.0.255) const_`[w`]char][@(64) _`*][@3 s][@(64) , - ][@(0.0.255) int][@(64) _][@3 from][@(64) )_][@(0.0.255) const]&] -[s2; Returns a position of substring of [%-*@3 len] characters [%-*@3 s] -greater or equal to [%-*@3 from], or `-1 if not found.&] -[s0; &] -[s5;K:`:`:AString`:`:Find`(const T`*`,int`)const:%- [@(0.0.255) int][@(64) _]Find[@(64) (][@(0.0.255) c -onst][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) , ][@(0.0.255) int][@(64) _][@3 from][@(64) _ -`=_][@3 0][@(64) )_][@(0.0.255) const]&] -[s2; Same as Find(strlen(s), s, from).&] -[s0; &] -[s5;K:`:`:AString`:`:Find`(const S`&`,int`)const:%- [@(0.0.255) int][@(64) _]Find[@(64) (][@(0.0.255) c -onst][@(64) _]`[W`]String[@(64) `&_][@3 s][@(64) , ][@(0.0.255) int][@(64) _][@3 from][@(64) _`=_ -][@3 0][@(64) )_][@(0.0.255) const]&] -[s2; Same as Find(s.GetLength(), s, from). &] -[s0; &] -[s5;K:`:`:AString`:`:StartsWith`(const T`*`,int`)const:%- [@(0.0.255) bool][@(64) _]Start -sWith[@(64) (][@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) , -][@(0.0.255) int][@(64) _][@3 len][@(64) )_][@(0.0.255) const]&] -[s2; Returns true if string [/ starts] with [%-*@3 len] characters [%-*@3 s].&] -[s0; &] -[s5;K:`:`:AString`:`:StartsWith`(const T`*`)const:%- [@(0.0.255) bool][@(64) _]StartsWith -[@(64) (][@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) )_][@(0.0.255) c -onst]&] -[s2; Same as StartsWith(s, strlen(s)).&] -[s0; &] -[s5;K:`:`:AString`:`:StartsWith`(const S`&`)const:%- [@(0.0.255) bool][@(64) _]StartsWith -[@(64) (][@(0.0.255) const][@(64) _]`[W`]String[@(64) `&_][@3 s][@(64) )_][@(0.0.255) const]&] -[s2; Same as StartsWith(s, s.GetLength()).&] -[s0; &] -[s5;K:`:`:AString`:`:EndsWith`(const T`*`,int`)const:%- [@(0.0.255) bool][@(64) _]EndsWit -h[@(64) (][@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) , -][@(0.0.255) int][@(64) _][@3 len][@(64) )_][@(0.0.255) const]&] -[s2; Returns true if string [/ ends] with [%-*@3 len] characters [%-*@3 s].&] -[s0; &] -[s5;K:`:`:AString`:`:EndsWith`(const T`*`)const:%- [@(0.0.255) bool][@(64) _]EndsWith[@(64) ( -][@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) )_][@(0.0.255) const]&] -[s2; Same as EndsWith(s, strlen(s)).&] -[s0; &] -[s5;K:`:`:AString`:`:EndsWith`(const S`&`)const:%- [@(0.0.255) bool][@(64) _]EndsWith[@(64) ( -][@(0.0.255) const][@(64) _]`[W`]String[@(64) `&_][@3 s][@(64) )_][@(0.0.255) const]&] -[s2; Same as EndsWith(s, s.GetLength()).&] -[s0; &] -[s5;K:`:`:AString`:`:Clear`(`):%- [@(0.0.255) void][@(64) _]Clear[@(64) ()]&] -[s2; Empties the string.&] -[s0; &] -[s5;K:`:`:AString`:`:Shrink`(`):%- [@(0.0.255) void][@(64) _]Shrink[@(64) ()]&] -[s2; Reduces memory used by string to minimum (size optimization).&] -[s0; &] -[s5;K:`:`:AString`:`:Reserve`(int`):%- [@(0.0.255) void][@(64) _]Reserve[@(64) (][@(0.0.255) i -nt][@(64) _][@3 len][@(64) )]&] -[s2; Preallocates enough memory to hold [%-*@3 len] (speed optimization).&] -[s0; &] -[s5;K:`:`:AString`:`:Begin`(`)const:%- [@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _ -`*]Begin[@(64) ()_][@(0.0.255) const]&] -[s2; Returns a pointer to the first character.&] -[s0; &] -[s5;K:`:`:AString`:`:End`(`)const:%- [@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _ -`*]End[@(64) ()_][@(0.0.255) const]&] -[s2; Returns a pointer to the ending zero.&] -[s0; &] -[s5;K:`:`:AString`:`:Last`(`)const:%- [@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _ -`*]Last[@(64) ()_][@(0.0.255) const]&] -[s2; Returns a pointer to the last character or to the ending zero -if there are no characters in string.&] -[s0; &] -[s5;K:`:`:String`:`:Cat`(int`):%- [@(0.0.255) void][@(64) _]Cat[@(64) (][@(0.0.255) int][@(64) _ -][@3 c][@(64) )]&] -[s5;K:`:`:String`:`:operator`+`=`(char`):%- [@(0.0.255) const][@(64) _][^`:`:String^@(64) S -tring][@(64) `&_]operator`+`=[@(64) (][@(0.0.255) `[w`]char][@(64) _][@3 c][@(64) )]&] -[s2; Appends single character. This operations has constant amortized -time (in other words, internal space used by implementation grows -exponentially, like with Vector or std`::vector).&] -[s0; &] -[s5;K:`:`:String`:`:Cat`(const char`*`):%- [@(0.0.255) void][@(64) _]Cat[@(64) (][@(0.0.255) c -onst][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) )]&] -[s5;K:`:`:String`:`:operator`+`=`(const char`*`):%- [@(0.0.255) const][@(64) _][^`:`:String^@(64) `[ -W`]String][@(64) `&_]operator`+`=[@(64) (][@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _ -`*][@3 s][@(64) )]&] -[s2; Appends a zero terminated string.&] -[s0; &] -[s5;K:`:`:String`:`:Cat`(const`:`:String`&`):%- [@(0.0.255) void][@(64) _]Cat[@(64) (][@(0.0.255) c -onst][@(64) _][^`:`:String^@(64) `[W`]String][@(64) `&_][@3 s][@(64) )]&] -[s5;K:`:`:String`:`:operator`+`=`(const`:`:String`&`):%- [@(0.0.255) const][@(64) _][^`:`:String^@(64) `[ -W`]String][@(64) `&_]operator`+`=[@(64) (][@(0.0.255) const][@(64) _][^`:`:String^@(64) `[W -`]String][@(64) `&_][@3 s][@(64) )]&] -[s2; Appends another strings.&] -[s0; &] -[s5;K:`:`:String`:`:Cat`(int`,int`):%- [@(0.0.255) void][@(64) _]Cat[@(64) (][@(0.0.255) int][@(64) _ -][@3 c][@(64) , ][@(0.0.255) int][@(64) _][@3 count][@(64) )]&] -[s2; Appends character [%-*@3 c] [%-*@3 count] times.&] -[s0; &] -[s5;K:`:`:String`:`:Cat`(const char`*`,int`):%- [@(0.0.255) void][@(64) _]Cat[@(64) (][@(0.0.255) c -onst][@(64) _][@(0.0.255) char][@(64) _`*][@3 s][@(64) , ][@(0.0.255) int][@(64) _][@3 len][@(64) ) -]&] -[s2; Appends string [%-*@3 s] with [%-*@3 len]. (There can be zeros in -[%-*@3 s]).&] -[s0; &] -[s5;K:`:`:String`:`:Cat`(const char`*`,const char`*`):%- [@(0.0.255) void][@(64) _]Cat[@(64) ( -][@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) , -][@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 lim][@(64) )]&] -[s2; Same as Cat([%-*@3 s], [%-*@3 lim] `- [%-*@3 s]).&] -[s0; &] -[s5;K:`:`:String`:`:Cat`(const`:`:String`&`,int`):%- [@(0.0.255) void][@(64) _]Cat[@(64) (][@(0.0.255) c -onst][@(64) _][^`:`:String^@(64) `[W`]String][@(64) `&_][@3 s][@(64) , -][@(0.0.255) int][@(64) _][@3 len][@(64) )]&] -[s2; Appends [%-*@3 len] characters from [%-*@3 s].&] -[s0; &] -[s5;K:`:`:String`:`:Cat`(`):%- [^`:`:String^ `[W`]String]`&_Cat[@(64) ()]&] -[s2; Returns `*this. This very specific functions is used to create -strings `"in`-place`" when calling other functions, e.g. Foo(String().Cat() -<< a << `" `= `" << b). Note that simple Foo(String() << a << -`" `= `" << b) does not work with standard C`+`+ as you cannot -pass temporary as non`-const parameter of `"<<`".&] -[s0; &] -[s5;K:`:`:String`:`:operator`=`(const char`*`):%- [^`:`:String^ `[W`]String]`&_operator -`=[@(64) (][@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) )]&] -[s2; Assigns zero terminated string.&] -[s0; &] -[s5;K:`:`:String`:`:operator`=`(const`:`:String`&`):%- [^`:`:String^ `[W`]String]`&_ope -rator`=[@(64) (][@(0.0.255) const][@(64) _][^`:`:String^@(64) `[W`]String][@(64) `&_][@3 s][@(64) ) -]&] -[s2; Assigns another string. This operations is relatively fast and -does not depend on the length of string.&] -[s0; &] -[s5;K:`:`:String`:`:operator`=`(`:`:String`:`:Buffer`&`):%- [^`:`:String^ String]`&_ope -rator`=[@(64) (][^`:`:String`:`:Buffer^@(64) `[W`]StringBuffer][@(64) `&_][@3 b][@(64) )]&] -[s2; Assigns the content of `[W`]StringBuffer. After the operation, -sources is empty.&] -[s0; &] -[s5;K:`:`:String`:`:operator`<`<`=`(const`:`:String`&`):%- [^`:`:String^ String]`&_oper -ator<<`=[@(64) (][@(0.0.255) const][@(64) _][^`:`:String^@(64) String][@(64) `&_][@3 s][@(64) ) -]&] -[s2; `"Deep`" assignment. It is equivalent of standard assignment -followed by Shrink operation (in other words, internal buffer -gets reallocated to the exact size of source).&] -[s0; &] -[s5;K:`:`:String`:`:Insert`(int`,int`):%- [@(0.0.255) void][@(64) _]Insert[@(64) (][@(0.0.255) i -nt][@(64) _][@3 at][@(64) , ][@(0.0.255) int][@(64) _][@3 c][@(64) )]&] -[s2; Insert character [%-*@3 c] at position [%-*@3 at].&] -[s0; &] -[s5;K:`:`:String`:`:Insert`(int`,const`:`:String`&`):%- [@(0.0.255) void][@(64) _]Insert[@(64) ( -][@(0.0.255) int][@(64) _][@3 at][@(64) , ][@(0.0.255) const][@(64) _][^`:`:String`:`:Buffer^@(64) `[ -W`]][^`:`:String^@(64) String][@(64) `&_][@3 s][@(64) )]&] -[s2; Insert character [%-*@3 s] at position [%-*@3 at].&] -[s0; &] -[s5;K:`:`:String`:`:Insert`(int`,const char`*`,int`):%- [@(0.0.255) void][@(64) _]Insert[@(64) ( -][@(0.0.255) int][@(64) _][@3 at][@(64) , ][@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _ -`*][@3 s][@(64) , ][@(0.0.255) int][@(64) _][@3 l][@(64) )]&] -[s2; Inserts first [%-*@3 l] characters of [%-*@3 s] at position [%-*@3 at].&] -[s0; &] -[s5;K:`:`:String`:`:Insert`(int`,const char`*`):%- [@(0.0.255) void][@(64) _]Insert[@(64) ( -][@(0.0.255) int][@(64) _][@3 at][@(64) , ][@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _ -`*][@3 s][@(64) )]&] -[s2; Inserts zero terminated [%-*@3 s] at position [%-*@3 at].&] -[s0; &] -[s5;K:`:`:String`:`:Mid`(int`,int`)const:%- [^`:`:String`:`:Buffer^ `[W`]][^`:`:String^ S -tring]_Mid[@(64) (][@(0.0.255) int][@(64) _][@3 pos][@(64) , ][@(0.0.255) int][@(64) _][@3 length -][@(64) )_][@(0.0.255) const]&] -[s2; Returns the substring starting at [%-*@3 pos] of [%-*@3 length] -characters.&] -[s0; &] -[s5;K:`:`:String`:`:Mid`(int`)const:%- [^`:`:String`:`:Buffer^ `[W`]][^`:`:String^ String -]_Mid[@(64) (][@(0.0.255) int][@(64) _][@3 pos][@(64) )_][@(0.0.255) const]&] -[s2; Inserts a substring starting at [%-*@3 pos] till the end of string.&] -[s0; &] -[s5;K:`:`:String`:`:Right`(int`)const:%- [^`:`:String`:`:Buffer^ `[W`]][^`:`:String^ Stri -ng]_Right[@(64) (][@(0.0.255) int][@(64) _][@3 count][@(64) )_][@(0.0.255) const]&] -[s2; Returns last [%-*@3 count] characters.&] -[s0; &] -[s5;K:`:`:String`:`:Left`(int`)const:%- [^`:`:String`:`:Buffer^ `[W`]][^`:`:String^ Strin -g]_Left[@(64) (][@(0.0.255) int][@(64) _][@3 count][@(64) )_][@(0.0.255) const]&] -[s2; Returns firs [%-*@3 count] characters (same as Mid(0, [%-*@3 count])).&] -[s0; &] -[s5;K:`:`:String`:`:IsEqual`(const`:`:String`&`)const:%- [@(0.0.255) bool][@(64) _]IsEqua -l[@(64) (][@(0.0.255) const][@(64) _][^`:`:String`:`:Buffer^@(64) `[W`]][^`:`:String^@(64) S -tring][@(64) `&_][@3 s][@(64) )_][@(0.0.255) const]&] -[s2; True if strings are equal.&] -[s0; &] -[s5;K:`:`:String`:`:IsEqual`(const char`*`)const:%- [@(0.0.255) bool][@(64) _]IsEqual[@(64) ( -][@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) )_][@(0.0.255) const]&] -[s2; True if strings are equal. [%-@3 s] is zero terminated.&] -[s0; &] -[s5;K:`:`:String`:`:Compare`(const`:`:String`&`)const:%- [@(0.0.255) int][@(64) _]Compare -[@(64) (][@(0.0.255) const][@(64) _][^`:`:String`:`:Buffer^@(64) `[W`]][^`:`:String^@(64) S -tring][@(64) `&_][@3 s][@(64) )_][@(0.0.255) const]&] -[s2; Lexicographic comparison, return `-1 if this string is lower, -0 for equality, 1 if this string is greater. Individual characters -are compared as unsigned integer values.&] -[s0; &] -[s5;K:`:`:String`:`:Compare`(const char`*`)const:%- [@(0.0.255) int][@(64) _]Compare[@(64) ( -][@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) )_][@(0.0.255) const]&] -[s2; Lexicographic comparison with zero terminated [%-*@3 s].&] -[s0; &] -[s5;K:`:`:String`:`:operator`~`(`)const:%- [@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char -][@(64) _`*]operator`~[@(64) ()_][@(0.0.255) const]&] -[s5;K:`:`:String`:`:operator const char`*`(`)const:%- operator[@(64) _][@(0.0.255) const][@(64) _ -][@(0.0.255) `[w`]char][@(64) `*()_][@(0.0.255) const]&] -[s2; Return a immutable pointer to zero terminated sequence of characters -with string`'s content (a pointer to String internal buffer). -This pointer is only valid until next modifying operation on -string (destructor included).&] -[s0; &] -[s5;K:`:`:String`:`:operator`*`(`)const:%- [@(0.0.255) int][@(64) _]operator`*[@(64) ()_][@(0.0.255) c -onst]&] -[s2; Returns first character of string or 0 if string is empty.&] -[s0; &] -[s5;K:`:`:String`:`:operator`[`]`(int`)const:%- [@(0.0.255) int][@(64) _]operator`[`][@(64) ( -][@(0.0.255) int][@(64) _][@3 i][@(64) )_][@(0.0.255) const]&] -[s2; Returns [%-*@3 i] character of string.&] -[s0; &] -[s5;K:`:`:String`:`:IsVoid`(`)const:%- [@(0.0.255) bool][@(64) _]IsVoid[@(64) ()_][@(0.0.255) c -onst]&] -[s2; Returns true if String is special value returned by GetVoid.&] -[s0; &] -[s5;K:`:`:String`:`:IsZero`(`)const:%- static [^`:`:String`:`:Buffer^ `[W`]][^`:`:String^ S -tring]_GetVoid[@(64) ()]&] -[s2; Returns special Void value. This value is same as empty string, +[s5;:String`:`:Shrink`(`): [@(0.0.255) void]_[* Shrink]()&] +[s2;%% Reduces memory used by string to minimum (size optimization).&] +[s4; &] +[s5;:String`:`:ToWString`(`)const: [_^WString^ WString]_[* ToWString]()_[@(0.0.255) const]&] +[s2;%% Convert String to WString using current default character +set.&] +[s3; &] +[s4; &] +[s5;:String`:`:ToString`(`)const: [@(0.0.255) const]_[_^String^ String][@(0.0.255) `&]_[* ToS +tring]()_[@(0.0.255) const]&] +[s2;%% Returns `*this. Useful because ToString is standard method +to convert concrete type to text, used by AsString template (and +therefore by operator << as well).&] +[s3; &] +[s4; &] +[s5;:String`:`:GetVoid`(`): [@(0.0.255) static] [_^String^ String]_[* GetVoid]()&] +[s2;%% Returns special Void value. This value is same as empty string, but IsVoid method returns true for it. It can be used in special scenarios where client code needs to distinguish between two empty values (let us say Void is `"more empty`"...). For example, LoadFile returns Void string if file failed to load, but normal empty string if it is empty.&] -[s0; &] -[s5;K:`:`:String`:`:ToString`(`)const:%- [@(0.0.255) const][@(64) _][^`:`:String`:`:Buffer^@(64) `[ -W`]][^`:`:String^@(64) String][@(64) `&_]ToString[@(64) ()_][@(0.0.255) const]&] -[s2; Returns `*this. Useful because ToString is standard method to -convert concrete type to text, used by AsString template (and -therefore by operator << as well).&] -[s0; &] -[s5;K:`:`:String`:`:`:`:String`(`):%- `[W`]String[@(64) ()]&] -[s2; Constructs empty `[W`]String.&] -[s0; &] -[s5;K:`:`:String`:`:`:`:String`(const`:`:Nuller`&`):%- `[W`]String[@(64) (][@(0.0.255) co -nst][@(64) _][^`:`:Nuller^@(64) Nuller][@(64) `&)]&] -[s2; Constructs empty `[W`]String. This variant is important to allow -assigning Null to String (which is same as assigning the empty -String).&] -[s0; &] -[s5;K:`:`:String`:`:`:`:String`(const`:`:String`&`):%- `[W`]String[@(64) (][@(0.0.255) co -nst][@(64) _]`[W`]String[@(64) `&_][@3 s][@(64) )]&] -[s2; Copy constructor.&] -[s0; &] -[s5;K:`:`:String`:`:`:`:String`(const char`*`):%- `[W`]String[@(64) (][@(0.0.255) const][@(64) _ -][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) )]&] -[s2; Constructor form zero terminated string.&] -[s0; &] -[s5;K:`:`:String`:`:`:`:String`(const`:`:String`&`,int`):%- `[W`]String[@(64) (][@(0.0.255) c -onst][@(64) _]`[W`]String[@(64) `&_][@3 s][@(64) , ][@(0.0.255) int][@(64) _][@3 n][@(64) )]&] -[s2; Constructs a string equal to first [%-*@3 n] characters of [%-*@3 s].&] -[s0; &] -[s5;K:`:`:String`:`:`:`:String`(const char`*`,int`):%- `[W`]String[@(64) (][@(0.0.255) co -nst][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) , ][@(0.0.255) int][@(64) _][@3 n][@(64) ) +[s3; &] +[s4; &] +[s5;:String`:`:IsVoid`(`)const: [@(0.0.255) bool]_[* IsVoid]()_[@(0.0.255) const]&] +[s2;%% Returns true if String is special value returned by GetVoid.&] +[s3; &] +[s4; &] +[s5;:String0`:`:IsEqual`(const String0`&`)const: [@(0.0.255) bool]_[* IsEqual]([@(0.0.255) c +onst]_[_^String0^ String][@(0.0.255) `&]_[*@3 s])_[@(0.0.255) const]&] +[s2;%% Return true if string is equal to [%-*@3 s].&] +[s3;%% &] +[s4; &] +[s5;:String0`:`:Compare`(const String0`&`)const: [@(0.0.255) int]_[* Compare]([@(0.0.255) c +onst]_[_^String0^ String0][@(0.0.255) `&]_[*@3 s])_[@(0.0.255) const]&] +[s2;%% Lexicographic comparison, return `-1 if this string is lower, +0 for equality, 1 if this string is greater. Individual characters +are compared as unsigned integer values.&] +[s3;%% &] +[s4; &] +[s5;:String0`:`:GetHashValue`(`)const: [@(0.0.255) unsigned]_[* GetHashValue]()_[@(0.0.255) c +onst]&] +[s2;%% Returns the hash value of the string.&] +[s3; &] +[s4; &] +[s5;:String0`:`:Cat`(int`): [@(0.0.255) void]_[* Cat]([@(0.0.255) int]_[*@3 c])&] +[s2;%% Appends single character [%-*@3 c]. This operations has constant +amortized time (in other words, internal space used by implementation +grows exponentially, like with Vector or std`::vector).&] +[s3;%% &] +[s4; &] +[s5;:String0`:`:Cat`(const char`*`,int`): [@(0.0.255) void]_[* Cat]([@(0.0.255) const]_[@(0.0.255) c +har]_`*[*@3 s], [@(0.0.255) int]_[*@3 len])&] +[s2; [%% Appends ][*@3 len][%% characters from string ][*@3 s] ([*@3 s ]can +contain zero characters).&] +[s3;%% &] +[s4; &] +[s5;:String0`:`:Set`(int`,int`): [@(0.0.255) void]_[* Set]([@(0.0.255) int]_[*@3 i], +[@(0.0.255) int]_[*@3 chr])&] +[s2;%% Replace character at position [%-*@3 i] with [%-*@3 chr].&] +[s3;%% &] +[s4; &] +[s5;:String0`:`:Trim`(int`): [@(0.0.255) void]_[* Trim]([@(0.0.255) int]_[*@3 pos])&] +[s2;%% Sets the number of characters (length) to [%-*@3 pos].&] +[s3;%% &] +[s4; &] +[s5;:String0`:`:Begin`(`)const: [@(0.0.255) const]_[@(0.0.255) char]_`*[* Begin]()_[@(0.0.255) c +onst]&] +[s2;%% Returns a pointer to the first character.&] +[s3; &] +[s4; &] +[s5;:String0`:`:End`(`)const: [@(0.0.255) const]_[@(0.0.255) char]_`*[* End]()_[@(0.0.255) co +nst]&] +[s2;%% Returns a pointer to ending zero.&] +[s3; &] +[s4; &] +[s5;:String0`:`:Remove`(int`,int`): [@(0.0.255) void]_[* Remove]([@(0.0.255) int]_[*@3 pos], +[@(0.0.255) int]_[*@3 count]_`=_[@3 1])&] +[s2;%% Removes [%-*@3 count] element starting at position [%-*@3 pos].&] +[s3;%% &] +[s4; &] +[s5;:String0`:`:Clear`(`): [@(0.0.255) void]_[* Clear]()&] +[s2;%% Empties the string.&] +[s3; &] +[s4; &] +[s5;:String0`:`:GetCount`(`)const: [@(0.0.255) int]_[* GetCount]()_[@(0.0.255) const]&] +[s5;:String0`:`:GetLength`(`)const: [@(0.0.255) int]_[* GetLength]()_[@(0.0.255) const]&] +[s2;%% Returns the number of characters.&] +[s3; &] +[s4; &] +[s5;:String0`:`:GetAlloc`(`)const: [@(0.0.255) int]_[* GetAlloc]()_[@(0.0.255) const]&] +[s2;%% Returns the number of allocated characters (maximum string +length before it has to grow) &] +[s3; &] +[s4; &] +[s5;:String0`:`:Reserve`(int`): [@(0.0.255) void]_[* Reserve]([@(0.0.255) int]_[*@3 r])&] +[s2;%% Reserves [%-*@3 r] characters of internal storage for future +concatenation operations.&] +[s3;%% &] +[s3; &] +[s3; &] +[s0;@(0.0.255)%% &] +[s0; [*+117 `[W`]String common methods]&] +[s0;@(0.0.255)%% &] +[s4; &] +[s5;:String0`:`:Remove`(int`,int`): [@(0.0.255) void]_[* Remove]([@(0.0.255) int]_[*@3 pos], +[@(0.0.255) int]_[*@3 count]_`=_[@3 1])&] +[s5;:WString0`:`:Remove`(int`,int`): [@(0.0.255) void]_[* Remove]([@(0.0.255) int]_[*@3 pos], + [@(0.0.255) int]_[*@3 count]_`=_[@3 1])&] +[s2;%% Removes [%-*@3 count] element starting at position [%-*@3 at].&] +[s0;%% &] +[s5;K:`:`:AString`:`:Set`(int`,int`): [@(0.0.255) void][@(64) _]Set[@(64) (][@(0.0.255) int][@(64) _ +][@3 at][@(64) , ][@(0.0.255) int][@(64) _][@3 chr][@(64) )]&] +[s2;%% Replace character at position [%-*@3 at] with [%-*@3 chr].&] +[s0;%% &] +[s5;K:`:`:AString`:`:Trim`(int`): [@(0.0.255) void][@(64) _]Trim[@(64) (][@(0.0.255) int][@(64) _ +][@3 at][@(64) )]&] +[s2;%% Sets the number of characters (length) to [%-*@3 at].&] +[s0;%% &] +[s5;K:`:`:AString`:`:GetLength`(`)const: [@(0.0.255) int][@(64) _]GetLength[@(64) ()_][@(0.0.255) c +onst]&] +[s5;K:`:`:AString`:`:GetCount`(`)const: [@(0.0.255) int][@(64) _]GetCount[@(64) ()_][@(0.0.255) c +onst]&] +[s2;%% Returns the number of characters.&] +[s0;%% &] +[s5;K:`:`:AString`:`:IsEmpty`(`)const: [@(0.0.255) bool][@(64) _]IsEmpty[@(64) ()_][@(0.0.255) c +onst]&] +[s2;%% Same as GetCount() `=`= 0.&] +[s0;%% &] +[s5;K:`:`:AString`:`:Find`(int`,int`)const: [@(0.0.255) int][@(64) _]Find[@(64) (][@(0.0.255) i +nt][@(64) _][@3 chr][@(64) , ][@(0.0.255) int][@(64) _][@3 from][@(64) _`=_][@3 0][@(64) )_][@(0.0.255) c +onst]&] +[s2;%% Returns a position of character equal to [%-*@3 chr] greater +or equal to [%-*@3 from], or `-1 if not found.&] +[s0;%% &] +[s5;K:`:`:AString`:`:ReverseFind`(int`,int`)const: [@(0.0.255) int][@(64) _]ReverseFind[@(64) ( +][@(0.0.255) int][@(64) _][@3 chr][@(64) , ][@(0.0.255) int][@(64) _][@3 from][@(64) )_][@(0.0.255) c +onst]&] +[s2;%% Returns a position of [/ last] character equal to [%-*@3 chr] +lower or equal to [%-*@3 from], or `-1 if not found.&] +[s0;%% &] +[s5;K:`:`:AString`:`:ReverseFind`(int`)const: [@(0.0.255) int][@(64) _]ReverseFind[@(64) (][@(0.0.255) i +nt][@(64) _][@3 chr][@(64) )_][@(0.0.255) const]&] +[s2;%% Returns a position of [/ last] character equal to [%-*@3 chr], +or `-1 if not found.&] +[s0;%% &] +[s5;K:`:`:AString`:`:Find`(int`,const T`*`,int`)const: [@(0.0.255) int][@(64) _]Find[@(64) ( +][@(0.0.255) int][@(64) _][@3 len][@(64) , ][@(0.0.255) const_`[w`]char][@(64) _`*][@3 s][@(64) , + ][@(0.0.255) int][@(64) _][@3 from][@(64) )_][@(0.0.255) const]&] +[s2;%% Returns a position of substring of [%-*@3 len] characters [%-*@3 s] +greater or equal to [%-*@3 from], or `-1 if not found.&] +[s0;%% &] +[s5;K:`:`:AString`:`:Find`(const T`*`,int`)const: [@(0.0.255) int][@(64) _]Find[@(64) (][@(0.0.255) c +onst][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) , ][@(0.0.255) int][@(64) _][@3 from][@(64) _ +`=_][@3 0][@(64) )_][@(0.0.255) const]&] +[s2;%% Same as Find(strlen(s), s, from).&] +[s0;%% &] +[s5;K:`:`:AString`:`:Find`(const S`&`,int`)const: [@(0.0.255) int][@(64) _]Find[@(64) (][@(0.0.255) c +onst][@(64) _]`[W`]String[@(64) `&_][@3 s][@(64) , ][@(0.0.255) int][@(64) _][@3 from][@(64) _`=_ +][@3 0][@(64) )_][@(0.0.255) const]&] +[s2;%% Same as Find(s.GetLength(), s, from). &] +[s0;%% &] +[s5;K:`:`:AString`:`:StartsWith`(const T`*`,int`)const: [@(0.0.255) bool][@(64) _]StartsW +ith[@(64) (][@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) , +][@(0.0.255) int][@(64) _][@3 len][@(64) )_][@(0.0.255) const]&] +[s2;%% Returns true if string [/ starts] with [%-*@3 len] characters +[%-*@3 s].&] +[s0;%% &] +[s5;K:`:`:AString`:`:StartsWith`(const T`*`)const: [@(0.0.255) bool][@(64) _]StartsWith[@(64) ( +][@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) )_][@(0.0.255) const]&] +[s2;%% Same as StartsWith(s, strlen(s)).&] +[s0;%% &] +[s5;K:`:`:AString`:`:StartsWith`(const S`&`)const: [@(0.0.255) bool][@(64) _]StartsWith[@(64) ( +][@(0.0.255) const][@(64) _]`[W`]String[@(64) `&_][@3 s][@(64) )_][@(0.0.255) const]&] +[s2;%% Same as StartsWith(s, s.GetLength()).&] +[s0;%% &] +[s5;K:`:`:AString`:`:EndsWith`(const T`*`,int`)const: [@(0.0.255) bool][@(64) _]EndsWith[@(64) ( +][@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) , +][@(0.0.255) int][@(64) _][@3 len][@(64) )_][@(0.0.255) const]&] +[s2;%% Returns true if string [/ ends] with [%-*@3 len] characters [%-*@3 s].&] +[s0;%% &] +[s5;K:`:`:AString`:`:EndsWith`(const T`*`)const: [@(0.0.255) bool][@(64) _]EndsWith[@(64) ( +][@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) )_][@(0.0.255) const]&] +[s2;%% Same as EndsWith(s, strlen(s)).&] +[s0;%% &] +[s5;K:`:`:AString`:`:EndsWith`(const S`&`)const: [@(0.0.255) bool][@(64) _]EndsWith[@(64) ( +][@(0.0.255) const][@(64) _]`[W`]String[@(64) `&_][@3 s][@(64) )_][@(0.0.255) const]&] +[s2;%% Same as EndsWith(s, s.GetLength()).&] +[s0;%% &] +[s5;K:`:`:AString`:`:Clear`(`): [@(0.0.255) void][@(64) _]Clear[@(64) ()]&] +[s2;%% Empties the string.&] +[s0;%% &] +[s5;K:`:`:AString`:`:Shrink`(`): [@(0.0.255) void][@(64) _]Shrink[@(64) ()]&] +[s2;%% Reduces memory used by string to minimum (size optimization).&] +[s0;%% &] +[s5;K:`:`:AString`:`:Reserve`(int`): [@(0.0.255) void][@(64) _]Reserve[@(64) (][@(0.0.255) in +t][@(64) _][@3 len][@(64) )]&] +[s2;%% Preallocates enough memory to hold [%-*@3 len] (speed optimization).&] +[s0;%% &] +[s5;K:`:`:AString`:`:Begin`(`)const: [@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _ +`*]Begin[@(64) ()_][@(0.0.255) const]&] +[s2;%% Returns a pointer to the first character.&] +[s0;%% &] +[s5;K:`:`:AString`:`:End`(`)const: [@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _`* +]End[@(64) ()_][@(0.0.255) const]&] +[s2;%% Returns a pointer to the ending zero.&] +[s0;%% &] +[s5;K:`:`:AString`:`:Last`(`)const: [@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _ +`*]Last[@(64) ()_][@(0.0.255) const]&] +[s2;%% Returns a pointer to the last character or to the ending zero +if there are no characters in string.&] +[s0;%% &] +[s5;K:`:`:String`:`:Cat`(int`): [@(0.0.255) void][@(64) _]Cat[@(64) (][@(0.0.255) int][@(64) _][@3 c +][@(64) )]&] +[s5;K:`:`:String`:`:operator`+`=`(char`): [@(0.0.255) const][@(64) _][^`:`:String^@(64) Str +ing][@(64) `&_]operator`+`=[@(64) (][@(0.0.255) `[w`]char][@(64) _][@3 c][@(64) )]&] +[s2;%% Appends single character. This operations has constant amortized +time (in other words, internal space used by implementation grows +exponentially, like with Vector or std`::vector).&] +[s0;%% &] +[s5;K:`:`:String`:`:Cat`(const char`*`): [@(0.0.255) void][@(64) _]Cat[@(64) (][@(0.0.255) co +nst][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) )]&] +[s5;K:`:`:String`:`:operator`+`=`(const char`*`): [@(0.0.255) const][@(64) _][^`:`:String^@(64) `[ +W`]String][@(64) `&_]operator`+`=[@(64) (][@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _ +`*][@3 s][@(64) )]&] +[s2;%% Appends a zero terminated string.&] +[s0;%% &] +[s5;K:`:`:String`:`:Cat`(const`:`:String`&`): [@(0.0.255) void][@(64) _]Cat[@(64) (][@(0.0.255) c +onst][@(64) _][^`:`:String^@(64) `[W`]String][@(64) `&_][@3 s][@(64) )]&] +[s5;K:`:`:String`:`:operator`+`=`(const`:`:String`&`): [@(0.0.255) const][@(64) _][^`:`:String^@(64) `[ +W`]String][@(64) `&_]operator`+`=[@(64) (][@(0.0.255) const][@(64) _][^`:`:String^@(64) `[W +`]String][@(64) `&_][@3 s][@(64) )]&] +[s2;%% Appends another strings.&] +[s0;%% &] +[s5;K:`:`:String`:`:Cat`(int`,int`): [@(0.0.255) void][@(64) _]Cat[@(64) (][@(0.0.255) int][@(64) _ +][@3 c][@(64) , ][@(0.0.255) int][@(64) _][@3 count][@(64) )]&] +[s2;%% Appends character [%-*@3 c] [%-*@3 count] times.&] +[s0;%% &] +[s5;K:`:`:String`:`:Cat`(const char`*`,int`): [@(0.0.255) void][@(64) _]Cat[@(64) (][@(0.0.255) c +onst][@(64) _][@(0.0.255) char][@(64) _`*][@3 s][@(64) , ][@(0.0.255) int][@(64) _][@3 len][@(64) ) ]&] -[s2; Constructs a string equal to first [%-*@3 n] characters of [%-*@3 s].&] -[s0; &] -[s5;K:`:`:String`:`:`:`:String`(const char`*`,const char`*`):%- `[W`]String[@(64) (][@(0.0.255) c +[s2;%% Appends string [%-*@3 s] with [%-*@3 len]. (There can be zeros +in [%-*@3 s]).&] +[s0;%% &] +[s5;K:`:`:String`:`:Cat`(const char`*`,const char`*`): [@(0.0.255) void][@(64) _]Cat[@(64) ( +][@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) , +][@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 lim][@(64) )]&] +[s2;%% Same as Cat([%-*@3 s], [%-*@3 lim] `- [%-*@3 s]).&] +[s0;%% &] +[s5;K:`:`:String`:`:Cat`(const`:`:String`&`,int`): [@(0.0.255) void][@(64) _]Cat[@(64) (][@(0.0.255) c +onst][@(64) _][^`:`:String^@(64) `[W`]String][@(64) `&_][@3 s][@(64) , +][@(0.0.255) int][@(64) _][@3 len][@(64) )]&] +[s2;%% Appends [%-*@3 len] characters from [%-*@3 s].&] +[s0;%% &] +[s5;K:`:`:String`:`:Cat`(`): [^`:`:String^ `[W`]String]`&_Cat[@(64) ()]&] +[s2;%% Returns `*this. This very specific functions is used to create +strings `"in`-place`" when calling other functions, e.g. Foo(String().Cat() +<< a << `" `= `" << b). Note that simple Foo(String() << a << +`" `= `" << b) does not work with standard C`+`+ as you cannot +pass temporary as non`-const parameter of `"<<`".&] +[s0;%% &] +[s5;K:`:`:String`:`:operator`=`(const char`*`): [^`:`:String^ `[W`]String]`&_operator`= +[@(64) (][@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) )]&] +[s2;%% Assigns zero terminated string.&] +[s0;%% &] +[s5;K:`:`:String`:`:operator`=`(const`:`:String`&`): [^`:`:String^ `[W`]String]`&_opera +tor`=[@(64) (][@(0.0.255) const][@(64) _][^`:`:String^@(64) `[W`]String][@(64) `&_][@3 s][@(64) ) +]&] +[s2;%% Assigns another string. This operations is relatively fast +and does not depend on the length of string.&] +[s0;%% &] +[s5;K:`:`:String`:`:operator`=`(`:`:String`:`:Buffer`&`): [^`:`:String^ String]`&_opera +tor`=[@(64) (][^`:`:String`:`:Buffer^@(64) `[W`]StringBuffer][@(64) `&_][@3 b][@(64) )]&] +[s2;%% Assigns the content of `[W`]StringBuffer. After the operation, +sources is empty.&] +[s0;%% &] +[s5;K:`:`:String`:`:operator`<`<`=`(const`:`:String`&`): [^`:`:String^ String]`&_operat +or<<`=[@(64) (][@(0.0.255) const][@(64) _][^`:`:String^@(64) String][@(64) `&_][@3 s][@(64) )]&] +[s2;%% `"Deep`" assignment. It is equivalent of standard assignment +followed by Shrink operation (in other words, internal buffer +gets reallocated to the exact size of source).&] +[s0;%% &] +[s5;K:`:`:String`:`:Insert`(int`,int`): [@(0.0.255) void][@(64) _]Insert[@(64) (][@(0.0.255) i +nt][@(64) _][@3 at][@(64) , ][@(0.0.255) int][@(64) _][@3 c][@(64) )]&] +[s2;%% Insert character [%-*@3 c] at position [%-*@3 at].&] +[s0;%% &] +[s5;K:`:`:String`:`:Insert`(int`,const`:`:String`&`): [@(0.0.255) void][@(64) _]Insert[@(64) ( +][@(0.0.255) int][@(64) _][@3 at][@(64) , ][@(0.0.255) const][@(64) _][^`:`:String`:`:Buffer^@(64) `[ +W`]][^`:`:String^@(64) String][@(64) `&_][@3 s][@(64) )]&] +[s2;%% Insert character [%-*@3 s] at position [%-*@3 at].&] +[s0;%% &] +[s5;K:`:`:String`:`:Insert`(int`,const char`*`,int`): [@(0.0.255) void][@(64) _]Insert[@(64) ( +][@(0.0.255) int][@(64) _][@3 at][@(64) , ][@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _ +`*][@3 s][@(64) , ][@(0.0.255) int][@(64) _][@3 l][@(64) )]&] +[s2;%% Inserts first [%-*@3 l] characters of [%-*@3 s] at position [%-*@3 at].&] +[s0;%% &] +[s5;K:`:`:String`:`:Insert`(int`,const char`*`): [@(0.0.255) void][@(64) _]Insert[@(64) (][@(0.0.255) i +nt][@(64) _][@3 at][@(64) , ][@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) ) +]&] +[s2;%% Inserts zero terminated [%-*@3 s] at position [%-*@3 at].&] +[s0;%% &] +[s5;K:`:`:String`:`:Mid`(int`,int`)const: [^`:`:String`:`:Buffer^ `[W`]][^`:`:String^ Str +ing]_Mid[@(64) (][@(0.0.255) int][@(64) _][@3 pos][@(64) , ][@(0.0.255) int][@(64) _][@3 length][@(64) ) +_][@(0.0.255) const]&] +[s2;%% Returns the substring starting at [%-*@3 pos] of [%-*@3 length] +characters.&] +[s0;%% &] +[s5;K:`:`:String`:`:Mid`(int`)const: [^`:`:String`:`:Buffer^ `[W`]][^`:`:String^ String]_ +Mid[@(64) (][@(0.0.255) int][@(64) _][@3 pos][@(64) )_][@(0.0.255) const]&] +[s2;%% Inserts a substring starting at [%-*@3 pos] till the end of +string.&] +[s0;%% &] +[s5;K:`:`:String`:`:Right`(int`)const: [^`:`:String`:`:Buffer^ `[W`]][^`:`:String^ String +]_Right[@(64) (][@(0.0.255) int][@(64) _][@3 count][@(64) )_][@(0.0.255) const]&] +[s2;%% Returns last [%-*@3 count] characters.&] +[s0;%% &] +[s5;K:`:`:String`:`:Left`(int`)const: [^`:`:String`:`:Buffer^ `[W`]][^`:`:String^ String]_ +Left[@(64) (][@(0.0.255) int][@(64) _][@3 count][@(64) )_][@(0.0.255) const]&] +[s2;%% Returns firs [%-*@3 count] characters (same as Mid(0, [%-*@3 count])).&] +[s0;%% &] +[s5;K:`:`:String`:`:IsEqual`(const`:`:String`&`)const: [@(0.0.255) bool][@(64) _]IsEqual[@(64) ( +][@(0.0.255) const][@(64) _][^`:`:String`:`:Buffer^@(64) `[W`]][^`:`:String^@(64) String][@(64) `& +_][@3 s][@(64) )_][@(0.0.255) const]&] +[s2;%% True if strings are equal.&] +[s0;%% &] +[s5;K:`:`:String`:`:IsEqual`(const char`*`)const: [@(0.0.255) bool][@(64) _]IsEqual[@(64) ( +][@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) )_][@(0.0.255) const]&] +[s2;%% True if strings are equal. [%-@3 s] is zero terminated.&] +[s0;%% &] +[s5;K:`:`:String`:`:Compare`(const`:`:String`&`)const: [@(0.0.255) int][@(64) _]Compare[@(64) ( +][@(0.0.255) const][@(64) _][^`:`:String`:`:Buffer^@(64) `[W`]][^`:`:String^@(64) String][@(64) `& +_][@3 s][@(64) )_][@(0.0.255) const]&] +[s2;%% Lexicographic comparison, return `-1 if this string is lower, +0 for equality, 1 if this string is greater. Individual characters +are compared as unsigned integer values.&] +[s0;%% &] +[s5;K:`:`:String`:`:Compare`(const char`*`)const: [@(0.0.255) int][@(64) _]Compare[@(64) (][@(0.0.255) c +onst][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) )_][@(0.0.255) const]&] +[s2;%% Lexicographic comparison with zero terminated [%-*@3 s].&] +[s0;%% &] +[s5;K:`:`:String`:`:operator`~`(`)const: [@(0.0.255) const][@(64) _][@(0.0.255) `[w`]char][@(64) _ +`*]operator`~[@(64) ()_][@(0.0.255) const]&] +[s5;K:`:`:String`:`:operator const char`*`(`)const: operator[@(64) _][@(0.0.255) const][@(64) _ +][@(0.0.255) `[w`]char][@(64) `*()_][@(0.0.255) const]&] +[s2;%% Return a immutable pointer to zero terminated sequence of +characters with string`'s content (a pointer to String internal +buffer). This pointer is only valid until next modifying operation +on string (destructor included).&] +[s0;%% &] +[s5;K:`:`:String`:`:operator`*`(`)const: [@(0.0.255) int][@(64) _]operator`*[@(64) ()_][@(0.0.255) c +onst]&] +[s2;%% Returns first character of string or 0 if string is empty.&] +[s0;%% &] +[s5;K:`:`:String`:`:operator`[`]`(int`)const: [@(0.0.255) int][@(64) _]operator`[`][@(64) ( +][@(0.0.255) int][@(64) _][@3 i][@(64) )_][@(0.0.255) const]&] +[s2;%% Returns [%-*@3 i] character of string.&] +[s0;%% &] +[s5;K:`:`:String`:`:IsVoid`(`)const: [@(0.0.255) bool][@(64) _]IsVoid[@(64) ()_][@(0.0.255) c +onst]&] +[s2;%% Returns true if String is special value returned by GetVoid.&] +[s0;%% &] +[s5;K:`:`:String`:`:IsZero`(`)const: static [^`:`:String`:`:Buffer^ `[W`]][^`:`:String^ S +tring]_GetVoid[@(64) ()]&] +[s2;%% Returns special Void value. This value is same as empty string, +but IsVoid method returns true for it. It can be used in special +scenarios where client code needs to distinguish between two +empty values (let us say Void is `"more empty`"...). For example, +LoadFile returns Void string if file failed to load, but normal +empty string if it is empty.&] +[s0;%% &] +[s5;K:`:`:String`:`:ToString`(`)const: [@(0.0.255) const][@(64) _][^`:`:String`:`:Buffer^@(64) `[ +W`]][^`:`:String^@(64) String][@(64) `&_]ToString[@(64) ()_][@(0.0.255) const]&] +[s2;%% Returns `*this. Useful because ToString is standard method +to convert concrete type to text, used by AsString template (and +therefore by operator << as well).&] +[s0;%% &] +[s5;K:`:`:String`:`:`:`:String`(`): `[W`]String[@(64) ()]&] +[s2;%% Constructs empty `[W`]String.&] +[s0;%% &] +[s5;K:`:`:String`:`:`:`:String`(const`:`:Nuller`&`): `[W`]String[@(64) (][@(0.0.255) cons +t][@(64) _][^`:`:Nuller^@(64) Nuller][@(64) `&)]&] +[s2;%% Constructs empty `[W`]String. This variant is important to +allow assigning Null to String (which is same as assigning the +empty String).&] +[s0;%% &] +[s5;K:`:`:String`:`:`:`:String`(const`:`:String`&`): `[W`]String[@(64) (][@(0.0.255) cons +t][@(64) _]`[W`]String[@(64) `&_][@3 s][@(64) )]&] +[s2;%% Copy constructor.&] +[s0;%% &] +[s5;K:`:`:String`:`:`:`:String`(const char`*`): `[W`]String[@(64) (][@(0.0.255) const][@(64) _ +][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) )]&] +[s2;%% Constructor form zero terminated string.&] +[s0;%% &] +[s5;K:`:`:String`:`:`:`:String`(const`:`:String`&`,int`): `[W`]String[@(64) (][@(0.0.255) c +onst][@(64) _]`[W`]String[@(64) `&_][@3 s][@(64) , ][@(0.0.255) int][@(64) _][@3 n][@(64) )]&] +[s2;%% Constructs a string equal to first [%-*@3 n] characters of [%-*@3 s].&] +[s0;%% &] +[s5;K:`:`:String`:`:`:`:String`(const char`*`,int`): `[W`]String[@(64) (][@(0.0.255) cons +t][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) , ][@(0.0.255) int][@(64) _][@3 n][@(64) ) +]&] +[s2;%% Constructs a string equal to first [%-*@3 n] characters of [%-*@3 s].&] +[s0;%% &] +[s5;K:`:`:String`:`:`:`:String`(const char`*`,const char`*`): `[W`]String[@(64) (][@(0.0.255) c onst][@(64) _][@(0.0.255) `[w`]char][@(64) _`*][@3 s][@(64) , ][@(0.0.255) const][@(64) _][@(0.0.255) `[ w`]char][@(64) _`*][@3 lim][@(64) )]&] -[s2; Constructs a string equal to first [%-*@3 lim] `- [%-*@3 s] characters +[s2;%% Constructs a string equal to first [%-*@3 lim] `- [%-*@3 s] characters of [%-*@3 s].&] -[s0; &] -[s5;K:`:`:String`:`:`:`:String`(int`,int`):%- `[W`]String[@(64) (][@(0.0.255) int][@(64) _][@3 c +[s0;%% &] +[s5;K:`:`:String`:`:`:`:String`(int`,int`): `[W`]String[@(64) (][@(0.0.255) int][@(64) _][@3 c hr][@(64) , ][@(0.0.255) int][@(64) _][@3 count][@(64) )]&] -[s2; Constructs a string consisting of [%-*@3 count] characters [%-*@3 chr].&] -[s0; &] -[s5;K:`:`:String`:`:`:`:String`(`:`:String`:`:Buffer`&`):%- `[W`]String[@(64) (][^`:`:String`:`:Buffer^@(64) `[ +[s2;%% Constructs a string consisting of [%-*@3 count] characters +[%-*@3 chr].&] +[s0;%% &] +[s5;K:`:`:String`:`:`:`:String`(`:`:String`:`:Buffer`&`): `[W`]String[@(64) (][^`:`:String`:`:Buffer^@(64) `[ W`]StringBuffer][@(64) `&_][@3 b][@(64) )]&] -[s2; Constructs a string from [%-*@3 b]. [%-*@3 b] is emptied by this +[s2;%% Constructs a string from [%-*@3 b]. [%-*@3 b] is emptied by this operation.&] -[s0; &] -[s5;K:`:`:String`:`:Swap`(`:`:String`&`,`:`:String`&`):%- friend_[@(0.0.255) void][@(64) _ -]Swap[@(64) (][^`:`:String^@(64) String][@(64) `&_][@3 a][@(64) , ][^`:`:String^@(64) String][@(64) `& +[s0;%% &] +[s5;K:`:`:String`:`:Swap`(`:`:String`&`,`:`:String`&`): friend_[@(0.0.255) void][@(64) _]S +wap[@(64) (][^`:`:String^@(64) String][@(64) `&_][@3 a][@(64) , ][^`:`:String^@(64) String][@(64) `& _][@3 b][@(64) )]&] -[s2; Optimized swap operation.&] -[s0; &] -[s5;K:`:`:String`:`:`:`:String`(const std`:`:string`&`):%- String[@(64) (][@(0.0.255) con -st][@(64) _][^std`:`:string^@(64) std`::string][@(64) `&_][@3 s][@(64) )]&] -[s2; Constructor to achieve minimal STL compatibility.&] -[s0; &] -[s0; &] -[s0; [*+117 String specific methods]&] -[s0; &] -[s5;K:`:`:String`:`:Cat`(const`:`:byte`*`,int`):%- [@(0.0.255) void][@(64) _]Cat[@(64) (][@(0.0.255) c +[s2;%% Optimized swap operation.&] +[s0;%% &] +[s5;K:`:`:String`:`:`:`:String`(const std`:`:string`&`): String[@(64) (][@(0.0.255) const +][@(64) _][^std`:`:string^@(64) std`::string][@(64) `&_][@3 s][@(64) )]&] +[s2;%% Constructor to achieve minimal STL compatibility.&] +[s0;%% &] +[s0;%% &] +[s0;%% [*+117 String specific methods]&] +[s0;%% &] +[s5;K:`:`:String`:`:Cat`(const`:`:byte`*`,int`): [@(0.0.255) void][@(64) _]Cat[@(64) (][@(0.0.255) c onst][@(64) _][^`:`:byte^@(64) byte][@(64) _`*][@3 s][@(64) , ][@(0.0.255) int][@(64) _][@3 len][@(64) ) ]&] -[s2; Appends [%-*@3 len] bytes starting at [%-*@3 s] to String.&] -[s5;K^`:`:WString^ &] -[s5;K:`:`:String`:`:operator const void`*`(`)const:%- operator[@(64) _][@(0.0.255) const][@(64) _ +[s2;%% Appends [%-*@3 len] bytes starting at [%-*@3 s] to String.&] +[s5;K^`:`:WString^%% &] +[s5;K:`:`:String`:`:operator const void`*`(`)const: operator[@(64) _][@(0.0.255) const][@(64) _ ][@(0.0.255) void][@(64) `*()_][@(0.0.255) const]&] -[s5;K:`:`:String`:`:operator const`:`:byte`*`(`)const:%- operator[@(64) _][@(0.0.255) con -st][@(64) _byte`*()_][@(0.0.255) const]&] -[s2; Return a immutable pointer to zero terminated sequence of bytes -with string`'s content (a pointer to String internal buffer). +[s5;K:`:`:String`:`:operator const`:`:byte`*`(`)const: operator[@(64) _][@(0.0.255) const +][@(64) _byte`*()_][@(0.0.255) const]&] +[s2;%% Return a immutable pointer to zero terminated sequence of +bytes with string`'s content (a pointer to String internal buffer). This pointer is only valid until next modifying operation on string (destructor included).&] -[s0;@(0.0.255) &] -[s5;K:`:`:String`:`:ToWString`(`)const:%- [^`:`:WString^ WString]_ToWString[@(64) ()_][@(0.0.255) c +[s0;@(0.0.255)%% &] +[s5;K:`:`:String`:`:ToWString`(`)const: [^`:`:WString^ WString]_ToWString[@(64) ()_][@(0.0.255) c onst]&] -[s2; Convert String to WString using current default charset.&] -[s0; &] -[s5;K:`:`:String`:`:`:`:String`(const`:`:byte`*`,int`):%- String[@(64) (][@(0.0.255) cons -t][@(64) _][^`:`:byte^@(64) byte][@(64) _`*][@3 s][@(64) , ][@(0.0.255) int][@(64) _][@3 n][@(64) ) -]&] -[s2; Constructs string equal to first [%-*@3 n] bytes of [%-*@3 s].&] -[s0; &] -[s0; &] -[s0; [*+117 WString specific methods]&] -[s0;* &] -[s5;K:`:`:WString`:`:ToString`(`)const:%- [^`:`:String^ String]_ToString[@(64) ()_][@(0.0.255) c +[s2;%% Convert String to WString using current default charset.&] +[s0;%% &] +[s5;K:`:`:String`:`:`:`:String`(const`:`:byte`*`,int`): String[@(64) (][@(0.0.255) const][@(64) _ +][^`:`:byte^@(64) byte][@(64) _`*][@3 s][@(64) , ][@(0.0.255) int][@(64) _][@3 n][@(64) )]&] +[s2;%% Constructs string equal to first [%-*@3 n] bytes of [%-*@3 s].&] +[s0;%% &] +[s0;%% &] +[s0;%% [*+117 WString specific methods]&] +[s0;*%% &] +[s5;K:`:`:WString`:`:ToString`(`)const: [^`:`:String^ String]_ToString[@(64) ()_][@(0.0.255) c onst]&] -[s2; Converts WString to String using current default charset. Also -serves as standard text conversion (for AsString and operator<< +[s2;%% Converts WString to String using current default charset. +Also serves as standard text conversion (for AsString and operator<< templates).&] -[s0; &] -[s0; &] -[s0; &] -[s0; &] -[s0; [*+117 `[W`]StringBuffer methods]&] -[s0; &] -[s0; &] -[s5;K:`:`:AStringBuffer`:`:operator T`*`(`):%- operator[@(64) _][@(0.0.255) `[w`]char][@(64) `* +[s0;%% &] +[s0;%% &] +[s0;%% &] +[s0;%% &] +[s0;%% [*+117 `[W`]StringBuffer methods]&] +[s0;%% &] +[s0;%% &] +[s5;K:`:`:AStringBuffer`:`:operator T`*`(`): operator[@(64) _][@(0.0.255) `[w`]char][@(64) `* ()]&] -[s5;K:`:`:AStringBuffer`:`:operator void`*`(`):%- operator[@(64) _][@(0.0.255) void][@(64) `* +[s5;K:`:`:AStringBuffer`:`:operator void`*`(`): operator[@(64) _][@(0.0.255) void][@(64) `* ()]&] -[s5;K:`:`:AStringBuffer`:`:operator`~`(`):%- [@(0.0.255) `[w`]char][@(64) _]`*operator`~[@(64) ( +[s5;K:`:`:AStringBuffer`:`:operator`~`(`): [@(0.0.255) `[w`]char][@(64) _]`*operator`~[@(64) ( )]&] -[s5;K:`:`:AStringBuffer`:`:Begin`(`):%- [@4 T]_`*Begin[@(64) ()]&] -[s2; Returns a pointer to the buffer of characters. Mutating operations +[s5;K:`:`:AStringBuffer`:`:Begin`(`): [@4 T]_`*Begin[@(64) ()]&] +[s2;%% Returns a pointer to the buffer of characters. Mutating operations invalidate this pointer.&] -[s0; &] -[s5;K:`:`:AStringBuffer`:`:End`(`):%- T_`*End[@(64) ()]&] -[s2; Returns Begin() `+ GetCount(). Mutating operations invalidate +[s0;%% &] +[s5;K:`:`:AStringBuffer`:`:End`(`): T_`*End[@(64) ()]&] +[s2;%% Returns Begin() `+ GetCount(). Mutating operations invalidate this pointer.&] -[s0; &] -[s5;K:`:`:AStringBuffer`:`:Cat`(int`):%- [@(0.0.255) void][@(64) _]Cat[@(64) (][@(0.0.255) in -t][@(64) _][@3 c][@(64) )]&] -[s2; Appends single character.&] -[s0; &] -[s5;K:`:`:AStringBuffer`:`:Cat`(int`,int`):%- [@(0.0.255) void][@(64) _]Cat[@(64) (][@(0.0.255) i +[s0;%% &] +[s5;K:`:`:AStringBuffer`:`:Cat`(int`): [@(0.0.255) void][@(64) _]Cat[@(64) (][@(0.0.255) int][@(64) _ +][@3 c][@(64) )]&] +[s2;%% Appends single character.&] +[s0;%% &] +[s5;K:`:`:AStringBuffer`:`:Cat`(int`,int`): [@(0.0.255) void][@(64) _]Cat[@(64) (][@(0.0.255) i nt][@(64) _][@3 c][@(64) , ][@(0.0.255) int][@(64) _][@3 count][@(64) )]&] -[s2; Appends [%-*@3 count] characters [%-*@3 c].&] -[s0; &] -[s5;K:`:`:AStringBuffer`:`:Cat`(const T`*`,int`):%- [@(0.0.255) void][@(64) _]Cat[@(64) (][@(0.0.255) c +[s2;%% Appends [%-*@3 count] characters [%-*@3 c].&] +[s0;%% &] +[s5;K:`:`:AStringBuffer`:`:Cat`(const T`*`,int`): [@(0.0.255) void][@(64) _]Cat[@(64) (][@(0.0.255) c onst][@(64) _][@4 T][@(64) _`*][@3 s][@(64) , ][@(0.0.255) int][@(64) _][@3 len][@(64) )]&] -[s2; Appends [%-*@3 len] characters of [%-*@3 s].&] -[s0; &] -[s5;K:`:`:AStringBuffer`:`:GetLength`(`)const:%- [@(0.0.255) int][@(64) _]GetLength[@(64) ( -)_][@(0.0.255) const]&] -[s5;K:`:`:AStringBuffer`:`:GetCount`(`)const:%- [@(0.0.255) int][@(64) _]GetCount[@(64) ()_ +[s2;%% Appends [%-*@3 len] characters of [%-*@3 s].&] +[s0;%% &] +[s5;K:`:`:AStringBuffer`:`:GetLength`(`)const: [@(0.0.255) int][@(64) _]GetLength[@(64) ()_ ][@(0.0.255) const]&] -[s2; Returns the number of characters in the buffer.&] -[s0; &] -[s5;K:`:`:AStringBuffer`:`:SetLength`(int`):%- [@4 T][@(64) _`*]SetLength[@(64) (][@(0.0.255) i +[s5;K:`:`:AStringBuffer`:`:GetCount`(`)const: [@(0.0.255) int][@(64) _]GetCount[@(64) ()_][@(0.0.255) c +onst]&] +[s2;%% Returns the number of characters in the buffer.&] +[s0;%% &] +[s5;K:`:`:AStringBuffer`:`:SetLength`(int`): [@4 T][@(64) _`*]SetLength[@(64) (][@(0.0.255) i nt][@(64) _][@3 len][@(64) )]&] -[s5;K:`:`:AStringBuffer`:`:SetCount`(int`):%- [@4 T][@(64) _`*]SetCount[@(64) (][@(0.0.255) i -nt][@(64) _][@3 len][@(64) )]&] -[s2; [%-*@3 len] &] -[s2; Returns a pointer to the buffer of characters. Mutating operations +[s5;K:`:`:AStringBuffer`:`:SetCount`(int`): [@4 T][@(64) _`*]SetCount[@(64) (][@(0.0.255) int +][@(64) _][@3 len][@(64) )]&] +[s2;%% [%-*@3 len] &] +[s2;%% Returns a pointer to the buffer of characters. Mutating operations invalidate this pointer.&] -[s0; &] -[s5;K:`:`:AStringBuffer`:`:Clear`(`):%- [@(0.0.255) void][@(64) _]Clear[@(64) ()]&] -[s2; Clears the content of StringBuffer.&] -[s0; &] -[s5;K:`:`:AStringBuffer`:`:Reserve`(int`):%- [@(0.0.255) void][@(64) _]Reserve[@(64) (][@(0.0.255) i +[s0;%% &] +[s5;K:`:`:AStringBuffer`:`:Clear`(`): [@(0.0.255) void][@(64) _]Clear[@(64) ()]&] +[s2;%% Clears the content of StringBuffer.&] +[s0;%% &] +[s5;K:`:`:AStringBuffer`:`:Reserve`(int`): [@(0.0.255) void][@(64) _]Reserve[@(64) (][@(0.0.255) i nt][@(64) _][@3 alloc][@(64) )]&] -[s2; Preallocates internal buffer (avoids resizing of internal buffer -up to [%-@3 alloc] characters).&] -[s0; &] -[s5;K:`:`:String`:`:Buffer`:`:Strlen`(`):%- [@(0.0.255) void][@(64) _]Strlen[@(64) ()]&] -[s2; Same as SetCount(strlen(Begin())). Useful for converting C strings -returned from system to String.&] -[s0; &] -[s5;K:`:`:String`:`:Buffer`:`:operator`=`(`:`:String`&`):%- [@(0.0.255) void][@(64) _]ope -rator`=[@(64) (][@(0.0.255) `[W`]][^`:`:String^@(64) String][@(64) `&_][@3 s][@(64) )]&] -[s2; Assigns content of [%-*@3 s] to StringBuffer. Clears [%-*@3 s].&] -[s0; &] -[s5;K:`:`:String`:`:Buffer`:`:`:`:String`:`:Buffer`(`):%- Buffer[@(64) ()]&] -[s2; Constructs empty buffer.&] -[s0; &] -[s5;K:`:`:String`:`:Buffer`:`:`:`:String`:`:Buffer`(int`):%- Buffer[@(64) (][@(0.0.255) i -nt][@(64) _][@3 length][@(64) )]&] -[s2; Constructs buffer of [%-*@3 length] characters.&] -[s0; &] -[s5;K:`:`:String`:`:Buffer`:`:`:`:String`:`:Buffer`(`:`:String`&`):%- Buffer[@(64) (][@(0.0.255) `[ +[s2;%% Preallocates internal buffer (avoids resizing of internal +buffer up to [%-@3 alloc] characters).&] +[s0;%% &] +[s5;K:`:`:String`:`:Buffer`:`:Strlen`(`): [@(0.0.255) void][@(64) _]Strlen[@(64) ()]&] +[s2;%% Same as SetCount(strlen(Begin())). Useful for converting C +strings returned from system to String.&] +[s0;%% &] +[s5;K:`:`:String`:`:Buffer`:`:operator`=`(`:`:String`&`): [@(0.0.255) void][@(64) _]opera +tor`=[@(64) (][@(0.0.255) `[W`]][^`:`:String^@(64) String][@(64) `&_][@3 s][@(64) )]&] +[s2;%% Assigns content of [%-*@3 s] to StringBuffer. Clears [%-*@3 s].&] +[s0;%% &] +[s5;K:`:`:String`:`:Buffer`:`:`:`:String`:`:Buffer`(`): Buffer[@(64) ()]&] +[s2;%% Constructs empty buffer.&] +[s0;%% &] +[s5;K:`:`:String`:`:Buffer`:`:`:`:String`:`:Buffer`(int`): Buffer[@(64) (][@(0.0.255) int +][@(64) _][@3 length][@(64) )]&] +[s2;%% Constructs buffer of [%-*@3 length] characters.&] +[s0;%% &] +[s5;K:`:`:String`:`:Buffer`:`:`:`:String`:`:Buffer`(`:`:String`&`): Buffer[@(64) (][@(0.0.255) `[ W`]][^`:`:String^@(64) String][@(64) `&_][@3 text][@(64) )]&] -[s2; Assigns content of [%-*@3 s] to StringBuffer. Clears [%-*@3 s].&] -[s0; &] -[s5;K:`:`:String`:`:Buffer`:`:`:`:String`:`:Buffer`(`:`:String`&`,int`):%- Buffer[@(64) ( +[s2;%% Assigns content of [%-*@3 s] to StringBuffer. Clears [%-*@3 s].&] +[s0;%% &] +[s5;K:`:`:String`:`:Buffer`:`:`:`:String`:`:Buffer`(`:`:String`&`,int`): Buffer[@(64) ( ][@(0.0.255) `[W`]][^`:`:String^@(64) String][@(64) `&_][@3 text][@(64) , ][@(0.0.255) int][@(64) _][@3 length][@(64) )]&] -[s2; Assigns content of [%-*@3 s] to StringBuffer and trims the length. +[s2;%% Assigns content of [%-*@3 s] to StringBuffer and trims the length. Clears [%-*@3 s].&] [s0; ] \ No newline at end of file diff --git a/uppsrc/Core/src.tpp/VectorMap$en-us.tpp b/uppsrc/Core/src.tpp/VectorMap$en-us.tpp index e7d9d8db7..20e2e606a 100644 --- a/uppsrc/Core/src.tpp/VectorMap$en-us.tpp +++ b/uppsrc/Core/src.tpp/VectorMap$en-us.tpp @@ -10,6 +10,7 @@ topic "VectorMap"; [i448;b42;O9;2 $$8,8#61672508125594000341940100500538:tparam] [b42;2 $$9,9#13035079074754324216151401829390:normal] [{_}%EN-US +[s1;:noref: [*@3;4 Vector]&] [s1;:noref:%- [@(0.0.255)3 template][3 _<][@(0.0.255)3 class][3 _][*@4;3 K][3 , ][@(0.0.255)3 class][3 _][*@4;3 T][3 , ][@(0.0.255)3 class][3 _][*@4;3 HashFn][3 _`=_StdHash][@(0.0.255)3 < ][*@4;3 K][@(0.0.255)3 >][3 _>]&] @@ -17,7 +18,7 @@ topic "VectorMap"; oveableAndDeepCopyOption][@(0.0.255) <][* VectorMap][@(0.0.255) <][*@4 K], [*@4 T], [*@4 HashFn][@(0.0.255) >]_>, [@(0.0.255) public]_[*_^AMap^@3 AMap][@(0.0.255) <]_[*@4 K ], [*@4 T], [_^Vector^ Vector][@(0.0.255) <][*@4 T][@(0.0.255) >], [*@4 HashFn]_>_&] -[s5;%- &] +[s0;%- &] [s8; [*@4 K]-|Type of keys. K must have deep copy constructor, be [/^topic`:`/`/Core`/srcdoc`/Moveable`$en`-us^ m oveable] and must have operator`=`= defined.&] [s8; [*@4 T]-|Type of elements stored in Vector. T is required to be @@ -34,48 +35,56 @@ specific for its flavor.&] [s9; Like any other NTL container, VectorMap is [*/^topic`:`/`/Core`/srcdoc`/Moveable`$en`-us^ m oveable][*/ ]type with [*/^topic`:`/`/Core`/srcdoc`/pick`_`$en`-us^ pick and optional deep copy] transfer semantics. Calling methods of -picked VectorMap is logic error with exception of&] -[s0; [C+75 void ][*C+75 operator`=][C+75 (pick`_ VectorMap`& ][*C@3+75 v][C+75 ) -][/+75 (defined by composition)]&] -[s0; [C+75 void ][*C+75 operator<<`=][C+75 (const AMap`& ][*C@3+75 v][C+75 )][+75 -][/+75 (defined in AMap)]&] -[s0; [C+75 void ][*C+75 Clear][C+75 ()]&] -[s0; [C+75 bool ][*C+75 IsPicked][C+75 () const]&] +picked VectorMap is logic error with exception of:&] +[s9;C+75 &] +[s0; [*C+75 void operator`=(pick`_ VectorMap`& ][*C@3+75 v][*C+75 ) ][*/C+75 (defined +by composition)]&] +[s0; [*C+75 void operator<<`=(const AMap`& ][*C@3+75 v][*C+75 ) ][*/C+75 (defined +in AMap)]&] +[s0; [*C+75 void Clear()]&] +[s0; [*C+75 bool IsPicked() const]&] +[s0;C+75 &] [s9; Optional deep copy operator is inherited from AMap class. Pick operator is implicitly defined by composition.&] -[s0;3%- &] -[ {{10000t/25b/25@1 [s0;%- [* Public Member List]]}}&] -[s0; &] -[s5;:VectorMap`:`:Pop`(`):%- [*@4 T]_[* Pop]()&] -[s2; Drops last element of VectorMap and returns its value.&] -[s7; [*/ Return value]-|Value of dropped element.&] -[s3;%- &] +[s1; &] +[ {{10000F(128)G(128)@1 [s0; [* Constructor Detail]]}}&] +[s0;%- &] +[s5;:VectorMap`:`:VectorMap`(`):%- [* VectorMap]()&] +[s2; Default constructor. Constructs empty [* VectorMap].&] +[s3; &] [s4;%- &] [s5;:VectorMap`:`:VectorMap`(const VectorMap`&`,int`):%- [* VectorMap]([@(0.0.255) const]_ [* VectorMap][@(0.0.255) `&]_[*@3 s], [@(0.0.255) int])&] [s2; Optional deep copy constructor.&] -[s2; [*1 Requires T to have deep copy constructor or optional deep -copy constructor.]&] -[s7; [*C@3 s]-|Source VectorMap.&] -[s0;:`:`:VectorMap`:`:VectorMap`(pick`_`:`:Index``&`,pick`_`:`:Vector``&`): [* V -ectorMap](pick`_ Index`& [*@3 ndx], pick`_ Vector`& [*@3 val])&] -[s2; Pick`-constructs VectorMap from Index of keys and Vector of -values. Both source containers should have the same number of -elements.&] -[s7; [*C@3 ndx]-|Source Index.&] -[s7; [*C@3 val]-|Source Vector.&] -[s3;%- &] +[s6; Requires T to have deep copy constructor or optional deep copy +constructor.&] +[s7; [%-*@3 s][%- -|]Source [* VectorMap].&] +[s3; &] +[s4;%- &] +[s5;:VectorMap`:`:VectorMap`(pick`_ Index``&`,pick`_ Vector``&`):%- [* V +ectorMap]([@(0.128.128) pick`_]_[_^Index^ Index][@(0.0.255) <][*@4 K], +[*@4 HashFn][@(0.0.255) >`&]_[*@3 ndx], [@(0.128.128) pick`_]_[_^Vector^ Vector][@(0.0.255) < +][*@4 T][@(0.0.255) >`&]_[*@3 val])&] +[s2; Pick`-constructs [* VectorMap] from [* Index] of keys and [* Vector] +of values. Both source containers should have the same number +of elements.&] +[s7; [%-*@3 ndx][%- -|]Source Index.&] +[s7; [%-*@3 val][%- -|]Source Vector.&] +[s3; &] [s4;%- &] [s5;:VectorMap`:`:VectorMap`(pick`_ Vector``&`,pick`_ Vector``&`):%- [* VectorM ap]([@(0.128.128) pick`_]_[_^Vector^ Vector][@(0.0.255) <][*@4 K][@(0.0.255) >`&]_[*@3 ndx], [@(0.128.128) pick`_]_[_^Vector^ Vector][@(0.0.255) <][*@4 T][@(0.0.255) >`&]_[*@3 val])&] -[s2; Pick`-constructs VectorMap from Vector of keys and Vector of -values. Both source containers should have the same number of -elements.&] -[s7; [*C@3 ndx]-|Source Vector of keys.&] -[s7; [*C@3 val]-|Source Vector of values.&] -[s3;%- &] -[s4;%- &] -[s5;:VectorMap`:`:VectorMap`(`):%- [* VectorMap]()&] -[s2; Default constructor. Constructs empty VectorMap.&] +[s2; Pick`-constructs [* VectorMap] from [* Vector] of keys and [* Vector] +of values. Both source containers should have the same number +of elements.&] +[s7; [%-*@3 ndx][%- -|]Source Vector of keys.&] +[s7; [%-*@3 val][%- -|]Source Vector of values.&] +[s1; &] +[ {{10000F(128)G(128)t/25b/25@1 [s0;%- [* Public Member List]]}}&] +[s0;%- &] +[s5;:VectorMap`:`:Pop`(`):%- [*@4 T]_[* Pop]()&] +[s2; Drops last element of VectorMap and returns its value.&] +[s7; [*/ Return value]-|Value of dropped element.&] +[s1; &] [s0; ] \ No newline at end of file