Returning a stream of int zero-extending the char values from a String can be done via chars():
String str = "hello world"; IntStream chars = str.chars();