Difference between revisions of "Str.lower"

From OpenEUO
Jump to: navigation, search
m (Created page with "== Calling Pattern == Call local r[,...] = sl.str.lower(a[,...]) Args a1...aN are strings, numbers, or nil Results r1...rN are strings == Usage Example == local s = sl.str...")
 
m (Usage Example)
Line 15: Line 15:
 
   'Two strings',
 
   'Two strings',
 
   'Three strings'
 
   'Three strings'
  local r1,r2,r3 = s.len(a,b,c)
+
  local r1,r2,r3 = s.lower(a,b,c)
 
  print(r1)
 
  print(r1)
 
  print(r2)
 
  print(r2)

Revision as of 18:31, 11 November 2010

Calling Pattern

Call

local r[,...] = sl.str.lower(a[,...])

Args

a1...aN are strings, numbers, or nil

Results

r1...rN are strings


Usage Example

local s = sl.str
local a,b,c =
  'One string',
  'Two strings',
  'Three strings'
local r1,r2,r3 = s.lower(a,b,c)
print(r1)
print(r2)
print(r3)
--> one string
--> two strings
--> three strings

Description

Lower returns the lowercase version of all string arguments. Numerics and booleans are converted to strings. Nils are converted to empty strings.

Upon Error

Lower fails silently. If lower receives no arguments then nil is returned.

See Also