Casts all items to a specific type.

// '1', '2', '3', '4'
Enumerable.create(1, 2, 3, 4)
          .cast('string');

Supported types

Name(s) / value(s)Description
(empty string)No cast
array, Arrayarray
bool, booleanboolean
enumerable, seq, sequence"Sequence"
func, functionFunction (wrapper)
int, integer(integer) number
null(null)
numbernumber
observable, ObservableObservable object
ObservableArray, observableArray, observablearrayObservableArray object
str, stringString