TextUtils.Replace(String, String[], String[]) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Return a new CharSequence in which each of the source strings is replaced by the corresponding element of the destinations.
public static string? Replace(string? template, string[]? sources, string[]? destinations);
static member Replace : string * string[] * string[] -> string
Parameters
- template
- String
The original text from which to make the result.
- sources
- String[]
The search strings whose first matches are marked for replacement.
- destinations
- String[]
The replacement text values, indexed to correspond to sources.
Returns
A copy of the template with the located matches replaced by their corresponding destination values.
Remarks
Return a new CharSequence in which each of the source strings is replaced by the corresponding element of the destinations.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.