String.fromCharCodes factory constructor

String.fromCharCodes(Iterable<int> charCodes, [ int start = 0, int end ])

Allocates a new String for the specified charCodes.

The charCodes can be UTF-16 code units or runes. If a char-code value is 16-bit, it is copied verbatim:

new String.fromCharCodes([68]); // 'D'

If a char-code value is greater than 16-bits, it is decomposed into a surrogate pair:

var clef = new String.fromCharCodes([0x1D11E]);
clef.codeUnitAt(0); // 0xD834
clef.codeUnitAt(1); // 0xDD1E

If start and end is provided, only the values of charCodes at positions from start to, but not including, end, are used. The start and end values must satisfy 0 <= start <= end <= charCodes.length.

Source

external factory String.fromCharCodes(Iterable<int> charCodes,
    [int start = 0, int end]);

© 2012 the Dart project authors
Licensed under the Creative Commons Attribution-ShareAlike License v4.0.
https://api.dartlang.org/stable/1.24.3/dart-core/String/String.fromCharCodes.html