strings.hlp 3.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. A Common Lisp compatible package of string and character functions in
  2. PSL is available by LOADing STRINGS. The following functions are
  3. defined, from Chapters 13 and 14 of the Common Lisp manual. CHAR and
  4. STRING are not defined because of other functions with the same name.
  5. ;;;; STANDARD-CHARP - non-control character
  6. ;;;; GRAPHICP - printable character
  7. ;;;; STRING-CHARP - a character that can be an element of a string
  8. ;;;; ALPHAP - an alphabetic character
  9. ;;;; UPPERCASEP - an uppercase letter
  10. ;;;; LOWERCASEP - a lowercase letter
  11. ;;;; BOTHCASEP - same as ALPHAP
  12. ;;;; DIGITP - a digit character (optional radix not supported)
  13. ;;;; ALPHANUMERICP - a digit or an alphabetic
  14. ;;;; CHAR= - strict character comparison
  15. ;;;; CHAR-EQUAL - similar character objects
  16. ;;;; CHAR< - strict character comparison
  17. ;;;; CHAR> - strict character comparison
  18. ;;;; CHAR-LESSP - ignore case and bits for CHAR<
  19. ;;;; CHAR-GREATERP - ignore case and bits for CHAR>
  20. ;;;; CHAR-CODE - character to integer conversion
  21. ;;;; CHAR-BITS - bits attribute of a character
  22. ;;;; CHAR-FONT - font attribute of a character
  23. ;;;; CODE-CHAR - integer to character conversion, optional bits, font ignored
  24. ;;;; CHARACTER - character plus bits and font, which are ignored
  25. ;;;; CHAR-UPCASE - raise a character
  26. ;;;; CHAR-DOWNCASE - lower a character
  27. ;;;; DIGIT-CHAR - convert character to digit (optional radix, bits, font NYI)
  28. ;;;; CHAR-INT - convert character to integer
  29. ;;;; INT-CHAR - convert integer to character
  30. ;;;; CHAR - fetch a character in a string
  31. ;;;; RPLACHAR - store a character in a string
  32. ;;;; STRING= - compare two strings (substring options not implemented)
  33. ;;;; STRING-EQUAL - compare two strings, ignoring case, bits and font
  34. ;;;; STRING< - lexicographic comparison of strings
  35. ;;;; STRING> - lexicographic comparison of strings
  36. ;;;; STRING<= - lexicographic comparison of strings
  37. ;;;; STRING>= - lexicographic comparison of strings
  38. ;;;; STRING<> - lexicographic comparison of strings
  39. ;;;; STRING-LESSP - lexicographic comparison of strings
  40. ;;;; STRING-GREATERP - lexicographic comparison of strings
  41. ;;;; STRING-NOT-GREATERP - lexicographic comparison of strings
  42. ;;;; STRING-NOT-LESSP - lexicographic comparison of strings
  43. ;;;; STRING-NOT-EQUAL - lexicographic comparison of strings
  44. ;;;; MAKE-STRING - construct a string
  45. ;;;; STRING-TRIM - remove leading and trailing characters from a string
  46. ;;;; STRING-LEFT-TRIM - remove leading characters from string
  47. ;;;; STRING-RIGHT-TRIM - remove trailing characters from string
  48. ;;;; STRING-UPCASE - copy and raise all alphabetic characters in string
  49. ;;;; NSTRING-UPCASE - destructively raise all alphabetic characters in string
  50. ;;;; STRING-DOWNCASE - copy and lower all alphabetic characters in string
  51. ;;;; NSTRING-DOWNCASE - destructively raise all alphabetic characters in string
  52. ;;;; STRING-CAPITALIZE - copy and raise first letter of all words in string
  53. ;;;; NSTRING-CAPITALIZE - destructively raise first letter of all words
  54. ;;;; STRING - coercion to a string
  55. ;;;; STRING-TO-LIST - unpack string characters into a list
  56. ;;;; STRING-TO-VECTOR - unpack string characters into a vector
  57. ;;;; SUBSTRING - subsequence restricted to strings
  58. ;;;; STRING-LENGTH - last index of a string, plus one