Version: | 1.0 |
Status: | Unspecified |
Date: | June 2001 |
Author: | Rocklyte Systems |
Copyright: | Rocklyte Systems (c) 1998-2001. All rights reserved. |
The Strings module provides a variety of string functions that are common to most programming languages and operating systems. This includes support for string conversions, searching, merging and so forth. This module supports strings of an unlimited length, so you do not need to worry about any possible limitations. As a bonus, this means that you can also use the string functions on large text files and documents (so long as you null terminate them).
The most important thing to remember is that some functions will return strings that have had their space allocated with the AllocMemory() function. If this is the case for a function you are using, make sure you call FreeMemory() on the resulting string before your program exits.
Function Index | |
FloatToStr | Converts a floating point number to a string. |
IntToStr | Converts an integer to a string. |
StrBuildArray | Builds an array of strings from a sequential string list. |
StrCalculate | Calculates the total of any string containing calculations. |
StrCapitalise | Capitalises a string. |
StrClone | Clones string data. |
StrCopy | Copies the characters of one string to another. |
StrExpand | Expands the size of a string by inserting spaces. |
StrInsert | Inserts a string into another string. |
StrLength | Calculates the length of a string. |
StrLineLength | Determines the line-length of a string. |
StrLower | Changes a string so that all alpha characters are in lower-case. |
StrNextLine | Returns a pointer to the next line in a string buffer. |
StrReplace | Replaces all occurances of a keyword or phrase within a given string. |
StrSearch | Searches a string for a particular keyword/phrase. |
StrShrink | Shrinks strings by destroying data. |
StrSort | Used to sort string arrays. |
StrToFloat | Converts strings to floating point numbers. |
StrToInt | Converts a string to an integer. |
StrTranslate | Translates object references that have been declared within strings. |
StrUpper | Changes a string so that all alpha characters are in upper-case. |
Function: | IntToStr() | ||||||
Short: | Converts an integer to a string. | ||||||
Synopsis: | LONG IntToStr(LARGE Integer, STRING String, LONG StringSize) | ||||||
Arguments: |
| ||||||
|
Function: | StrBuildArray() | ||||||||
Short: | Builds an array of strings from a sequential string list. | ||||||||
Synopsis: | STRING * StrBuildArray(STRING List, LONG Size, LONG AmtEntries, LONG Flags) | ||||||||
Arguments: |
| ||||||||
|
Function: | StrCalculate() | |||||||||
Short: | Calculates the total of any string containing calculations. | |||||||||
Synopsis: | ERROR StrCalculate(STRING String, DOUBLE *Result) | |||||||||
Arguments: |
| |||||||||
|
Function: | StrCapitalise() | ||
Short: | Capitalises a string. | ||
Synopsis: | void StrCapitalise(STRING String) | ||
Arguments: |
| ||
|
Function: | StrClone() | |||
Short: | Clones string data. | |||
Synopsis: | STRING StrClone(STRING String) | |||
Arguments: |
| |||
|
Function: | StrCopy() | ||||||
Short: | Copies the characters of one string to another. | ||||||
Synopsis: | LONG StrCopy(STRING Source, STRING Destination, LONG Length) | ||||||
Arguments: |
| ||||||
|
Function: | StrExpand() | ||||||
Short: | Expands the size of a string by inserting spaces. | ||||||
Synopsis: | LONG StrExpand(STRING String, LONG Position, LONG TotalChars) | ||||||
Arguments: |
| ||||||
|
Function: | StrInsert() | |||||||
Short: | Inserts a string into another string. | |||||||
Synopsis: | ERROR StrInsert(STRING String, STRING Destination, LONG Position) | |||||||
Arguments: |
| |||||||
|
Function: | StrLength() | |||
Short: | Calculates the length of a string. | |||
Synopsis: | LONG StrLength(STRING String) | |||
Arguments: |
| |||
|
Function: | StrLineLength() | |||
Short: | Determines the line-length of a string. | |||
Synopsis: | LONG StrLineLength(STRING String) | |||
Arguments: |
| |||
|
Function: | StrLower() | ||
Short: | Changes a string so that all alpha characters are in lower-case. | ||
Synopsis: | void StrLower(STRING String) | ||
Arguments: |
| ||
|
Function: | StrNextLine() | |||
Short: | Returns a pointer to the next line in a string buffer. | |||
Synopsis: | STRING StrNextLine(STRING Buffer); | |||
Arguments: |
| |||
|
Function: | StrReplace() | |||||||||||
Short: | Replaces all occurances of a keyword or phrase within a given string. | |||||||||||
Synopsis: | ERROR StrReplace(STRING Source, STRING Keyword, STRING Replacement, STRING *Result, LONG CaseSensitive) | |||||||||||
Arguments: |
| |||||||||||
|
Function: | StrSearch() | ||||||
Short: | Searches a string for a particular keyword/phrase. | ||||||
Synopsis: | LONG StrSearch(STRING Keyword, STRING String, LONG CaseSensitive) | ||||||
Arguments: |
| ||||||
|
Function: | StrShrink() | ||||||
Short: | Shrinks strings by destroying data. | ||||||
Synopsis: | void StrShrink(STRING String, LONG Position, LONG AmtChars) | ||||||
Arguments: |
| ||||||
|
Function: | StrSort() | |||||||
Short: | Used to sort string arrays. | |||||||
Synopsis: | ERROR StrSort(STRING *List) | |||||||
Arguments: |
| |||||||
|
Function: | StrToFloat() | |||
Short: | Converts strings to floating point numbers. | |||
Synopsis: | DOUBLE StrToFloat(STRING String) | |||
Arguments: |
| |||
|
Function: | StrToInt() | |||
Short: | Converts a string to an integer. | |||
Synopsis: | LARGE StrToInt(STRING String) | |||
Arguments: |
| |||
|
Function: | StrTranslate() | |||||||||||||||||||||
Short: | Translates object references that have been declared within strings. | |||||||||||||||||||||
Synopsis: | ERROR StrTranslate(STRING Buffer, LONG Length) | |||||||||||||||||||||
Arguments: |
| |||||||||||||||||||||
|
Function: | StrUpper() | ||
Short: | Changes a string so that all alpha characters are in upper-case. | ||
Synopsis: | void StrUpper(STRING String) | ||
Arguments: |
| ||
|