Top Level Namespace
Defined in:
Method Summary
- available_encoders : Array(EncoderSpec)
- encode(str, encoders)
- encoder_help_lines : Array(String)
-
find(str, match : String)
Finds the first match of a regex pattern in a string Returns a Regex::MatchData if found, nil otherwise
-
find(str, match : Regex)
Finds the first match of a compiled regex in a string Returns a Regex::MatchData if found, nil otherwise
-
replace(str, find, replacement)
Replaces all occurrences of a substring with a replacement string Returns a new string with all substitutions made
Method Detail
def find(str, match : String)
#
Finds the first match of a regex pattern in a string Returns a Regex::MatchData if found, nil otherwise
def find(str, match : Regex)
#
Finds the first match of a compiled regex in a string Returns a Regex::MatchData if found, nil otherwise
def replace(str, find, replacement)
#
Replaces all occurrences of a substring with a replacement string Returns a new string with all substitutions made