XLISP > XLISP 2.0  -  Contents  -  Reference  -  Previous | Next

25  String Functions


  1. string - make a string from an integer ascii value
  2. string-trim - trim both ends of a string
  3. string-left-trim - trim the left end of a string
  4. string-right-trim - trim the right end of a string
  5. string-upcase - convert a string to uppercase
  6. string-downcase - convert a string to lowercase
  7. nstring-upcase - convert a part of a string to uppercase
  8. nstring-downcase - convert a part of a string to lowercase
  9. strcat - concatenate strings
  10. subseq - extract a substring
  11. string< - test for less than in ASCII ordering
  12. string<= - test for less than or equal to in ASCII ordering
  13. string= - test for equal to in ASCII ordering
  14. string/= - test for not equal to in ASCII ordering
  15. string>= - test for greater than or equal to in ASCII ordering
  16. string> - test for greater than in ASCII ordering
  17. string-lessp - is this less than in ASCII ordering ?
  18. string-not-greaterp - is this not greater than in ASCII ordering ?
  19. string-equal - is this equal in ASCII ordering ?
  20. string-not-equal - is this not equal in ASCII ordering ?
  21. string-not-lessp - is this not less than in ASCII ordering ?
  22. string-greaterp - is this greater than in ASCII ordering ?

(string expr) - make a string from a symbol, character or string
expr - a symbol, character or string expression
returns - a string

(string-trim bag str) - trim both ends of a string
bag - a string containing characters to trim
str - the string to trim
returns - a trimed copy of the string

(string-left-trim bag str) - trim the left end of a string
bag - a string containing characters to trim
str - the string to trim
returns - a trimed copy of the string

(string-right-trim bag str) - trim the right end of a string
bag - a string containing characters to trim
str - the string to trim
returns - a trimed copy of the string

(string-upcase str &key :start :end) - convert to uppercase
str - the string
:start - the starting offset
:end - the ending offset + 1
returns - a converted copy of the string

(string-downcase str &key :start :end) - convert to lowercase
str - the string
:start - the starting offset
:end - the ending offset + 1
returns - a converted copy of the string

(nstring-upcase str &key :start :end) - convert to uppercase
str - the string
:start - the starting offset
:end - the ending offset + 1
returns - the converted string [not a copy]

(nstring-downcase str &key :start :end) - convert to lowercase
str - the string
:start - the starting offset
:end - the ending offset + 1
returns - the converted string [not a copy]

(strcat expr...) - concatenate strings
expr - the strings to concatenate
returns - the result of concatenating the strings

(subseq string start [end]) - extract a substring
string - the string
start - the starting position [zero origin]
end - the ending position + 1 [defaults to end]
returns - substring between start and end

(string< str1 str2 &key :start1 :end1 :start2 :end2)
(string<= str1 str2 &key :start1 :end1 :start2 :end2)
(string= str1 str2 &key :start1 :end1 :start2 :end2)
(string/= str1 str2 &key :start1 :end1 :start2 :end2)
(string>= str1 str2 &key :start1 :end1 :start2 :end2)
(string> str1 str2 &key :start1 :end1 :start2 :end2)
str1 - the first string to compare
str2 - the second string to compare
:start1 - first substring starting offset
:end1 - first substring ending offset + 1
:start2 - second substring starting offset
:end2 - second substring ending offset + 1
returns - a non-NIL value if the predicate is true, NIL otherwise
Note: case is significant with these comparison functions.

(string-lessp str1 str2 &key :start1 :end1 :start2 :end2)
(string-not-greaterp str1 str2 &key :start1 :end1 :start2 :end2)
(string-equal str1 str2 &key :start1 :end1 :start2 :end2)
(string-not-equal str1 str2 &key :start1 :end1 :start2 :end2)
(string-not-lessp str1 str2 &key :start1 :end1 :start2 :end2)
(string-greaterp str1 str2 &key :start1 :end1 :start2 :end2)
str1 - the first string to compare
str2 - the second string to compare
:start1 - first substring starting offset
:end1 - first substring ending offset + 1
:start2 - second substring starting offset
:end2 - second substring ending offset + 1
returns - T if predicate is true, NIL otherwise
Note: case is not significant with these comparison functions.

XLISP > XLISP 2.0  -  Contents  -  Reference  -  Previous | Next