Module string

Module string 

Source
Expand description

String manipulation built-in functions

Functions§

char_at
获取指定位置的字符
contains
检查是否包含子字符串
ends_with
检查是否以指定后缀结尾
index_of
查找子串位置
lower
转换为小写
repeat
重复字符串
replace
替换字符串中的所有匹配项
split
分割字符串
starts_with
检查是否以指定前缀开头
strlen
获取字符串长度
substr
字符串切片
trim
去除首尾空白字符
upper
转换为大写