Functions
Constructing
from_bytearray
from_bytearray(bytes: ByteArray) -> StringConvert a ByteArray into a String
string.from_bytearray("foo") == @"foo"
string.from_bytearray(#"666f6f") == @"foo"
string.from_bytearray(some_hash) -> 💥from_int
from_int(n: Int) -> StringConvert an Int to its String representation.
string.from_int(42) == @"42"Combining
concat
concat(left: String, right: String) -> StringCombine two String together.
string.concat(left: @"Hello", right: @", World!") == @"Hello, World!"join
join(list: List<String>, delimiter: String) -> StringJoin a list of strings, separated by a given delimiter.
string.join([], @"+") == @""
string.join([@"a", @"b", @"c"], @",") == @"a,b,c"Transforming
to_bytearray
to_bytearray(self: String) -> ByteArrayConvert a String into a ByteArray
string.to_bytearray(@"foo") == "foo"