String methods syntax: Difference between revisions
m (Automatically generated page update) |
m (Automatically generated page update) |
||
Line 26: | Line 26: | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%string</span><span class="literal">=</span> <span class="term">string</span><span class="literal">:[[Inflate (String function)|Inflate]]</span></p> | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%string</span><span class="literal">=</span> <span class="term">string</span><span class="literal">:[[Inflate (String function)|Inflate]]</span></p> | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%string</span><span class="literal">=</span> <span class="term">string</span><span class="literal">:[[Insert (String function)|Insert]]</span><span class="literal">(</span> <span class="term">string</span><span class="comma">,</span> <span class="term">position</span><span class="literal">)</span></p> | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%string</span><span class="literal">=</span> <span class="term">string</span><span class="literal">:[[Insert (String function)|Insert]]</span><span class="literal">(</span> <span class="term">string</span><span class="comma">,</span> <span class="term">position</span><span class="literal">)</span></p> | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">% | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%boolean</span><span class="literal">=</span> <span class="term">string</span><span class="literal">:[[IsOneOf (String function)|IsOneOf]]</span><span class="literal">(</span> <span class="term">list</span><span class="literal">)</span></p> | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%string</span><span class="literal">=</span> <span class="term">string</span><span class="literal">:[[Left (String function)|Left]]</span><span class="literal">(</span> <span class="term">length</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal">Pad=</span> <span class="term">pad</span><span class="squareb">]</span><span class="literal">)</span></p> | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%string</span><span class="literal">=</span> <span class="term">string</span><span class="literal">:[[Left (String function)|Left]]</span><span class="literal">(</span> <span class="term">length</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal">Pad=</span> <span class="term">pad</span><span class="squareb">]</span><span class="literal">)</span></p> | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%length</span><span class="literal">=</span> <span class="term">string</span><span class="literal">:[[Length (String function)|Length]]</span></p> | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%length</span><span class="literal">=</span> <span class="term">string</span><span class="literal">:[[Length (String function)|Length]]</span></p> |
Revision as of 16:54, 19 January 2011
The syntax for each of the String class methods is shown below.
Square brackets indicate optional elements of the method invocation. See also the notation conventions for methods and the List of String methods.
%string= string:AsciiToEbcdic[( [CharacterEncode= characterEncode])]
%string= string:Base64ToString
%number= string:BinaryToFloat
%number= string:BinaryToInteger[( [Signed= signed])]
%string= string:Center( length, [Pad= pad], [OffsetLeft= offsetLeft])
%string= string:Centre( length, [Pad= pad], [OffsetLeft= offsetLeft])
%string= string:Char( position)
%string= string:Deflate[( [FixedCode= fixedCode], [LazyMatch= lazyMatch], - [MaxChain= maxChain])]
%string= string:EbcdicToAscii[( [CharacterDecode= characterDecode])]
%object= string:EbcdicToUnicode[( [CharacterDecode= characterDecode], - [Untranslatable= untranslatable])]
%number= string:GetCharacterPairValue( characterPairValueFunction)
%number= string:GetCharacterValue( characterValueFunction)
%string= string:Gunzip
%number= string:GunzipDatetimeNS
%string= string:GunzipFilename
%string= string:Gzip[( [FixedCode= fixedCode], [LazyMatch= lazyMatch], - [MaxChain= maxChain], [Filename= filename], - [LastModified= lastModified])]
%number= string:HexToInteger[( [Signed= signed])]
%string= string:HexToString
%string= string:Inflate
%string= string:Insert( string, position)
%boolean= string:IsOneOf( list)
%string= string:Left( length, [Pad= pad])
%length= string:Length
%string= string:MD5digest
%string= string:MarksStoreCodeDecrement
%string= string:MarksStoreCodeIncrement
%number= string:MarksStoreCodeToNumber
%object= string:ParseLines[( [string], [StripTrailingNull= stripTrailingNull])]
%position= string:PositionIn( string, [Start= start])
%position= string:PositionOf( string, [Start= start])
%string= string:RC4decrypt( string)
%string= string:RC4encrypt( string)
%number= string:RegexMatch( string, [Options= options], - [CaptureList= captureList])
%string= string:RegexReplace( string, string, [Options= options])
%object= string:RegexSplit( string, [Options= options], [Add= add])
%string= string:Remove( string, [Count= count])
%string= string:Replace( string, string, [Count= count])
%string= string:Reverse
%string= string:Right( length, [Pad= pad])
%string= string:SHAdigest
%string= string:StringToBase64
%number= string:StringToDays( string, [number])
%string= string:StringToHex
%number= string:StringToMilliseconds( string, [number])
%number= string:StringToSeconds( string, [number])
%string= string:Substring( position, [length], [Pad= pad])
%string= string:ToLower
%string= string:ToString
%string= string:ToUpper
%string= string:Translate( characterMap)
%object= string:U
%string= string:Unspace[( [Spaces= spaces], [Leading= leading], - [Trailing= trailing], [Compress= compress])]
%object= string:Utf16ToUnicode[( [AllowUntranslatable= allowUntranslatable], - [Bom= bom])]
%object= string:Utf8ToUnicode[( [AllowUntranslatable= allowUntranslatable])]
%string= string:X
%string= string:Zip[( [FixedCode= fixedCode], [LazyMatch= lazyMatch], - [MaxChain= maxChain], [Filename= filename], - [LastModified= lastModified])]
%object= string:stringTokenizer[( [TokenChars= tokenChars], [Spaces= spaces], - [Quotes= quotes], [Separators= separators])]