string module
Maylang standard-library module.
import "string" as string;
Module note —
wordssplits ASCII space, tab, carriage return and newline, dropping empty fields.
Functions
is_empty
pub fun is_empty(s: Str) -> BoolNo description yet. Read the declaration source for the exact contract.
supported · full runtime · source
repeat
pub fun repeat(s: Str, n: Int) -> StrNo description yet. Read the declaration source for the exact contract.
supported · full runtime · source
capitalize
pub fun capitalize(s: Str) -> StrNo description yet. Read the declaration source for the exact contract.
supported · full runtime · source
words
pub fun words(s: Str) -> List<Str>No description yet. Read the declaration source for the exact contract.
supported · full runtime · source
lines
pub fun lines(s: Str) -> List<Str>No description yet. Read the declaration source for the exact contract.
supported · full runtime · source
csv
pub fun csv(s: Str) -> List<Str>No description yet. Read the declaration source for the exact contract.
supported · full runtime · source
reverse_str
pub fun reverse_str(s: Str) -> StrNo description yet. Read the declaration source for the exact contract.
supported · full runtime · source
pad_left
pub fun pad_left(s: Str, width: Int, ch: Str) -> StrNo description yet. Read the declaration source for the exact contract.
supported · full runtime · source
pad_right
pub fun pad_right(s: Str, width: Int, ch: Str) -> StrNo description yet. Read the declaration source for the exact contract.
supported · full runtime · source
starts_with_any
pub fun starts_with_any(s: Str, prefixes: List<Str>) -> BoolNo description yet. Read the declaration source for the exact contract.
supported · full runtime · source
count_occurrences
pub fun count_occurrences(s: Str, needle: Str) -> IntNo description yet. Read the declaration source for the exact contract.
supported · full runtime · source
truncate
pub fun truncate(s: Str, width: Int, ellipsis: Str) -> StrNo description yet. Read the declaration source for the exact contract.
supported · full runtime · source