getTokens

getTokens(): StringArray;

The getTokens method of the String primitive type returns an array of the tokens in the receiver that have a length not greater than 62 characters. For details about tokens, see the getNextToken method.

The following example shows the use of the getTokens method.

vars
    stringValue : String;
    stringArray : StringArray;
begin
    stringValue := 'this:is/a;string';
    stringArray := stringValue.getTokens;
    write stringArray [1];        // Outputs this
    write stringArray [2];        // Outputs is
    write stringArray [3];        // Outputs a
    write stringArray [4];        // Outputs string
end;