reactor-core/src/main/java/reactor/core/publisher/Flux.java
public final <E> Flux<E> cast(Class<E> clazz) {
		Objects.requireNonNull(clazz, "clazz");
		return map(clazz::cast);
	}
public final <E> Flux<E> cast(Class<E> clazz) {
		Objects.requireNonNull(clazz, "clazz");
		return map(clazz::cast);
	}
public final < E > Flux < E > cast ( Class < E > clazz ) { Objects . requireNonNull ( clazz , "clazz" ) ; return map ( clazz :: cast ) ; }
Cast the current {@link Flux} produced type into a target produced type.

<p>
<img class="marble" src="doc-files/marbles/castForFlux.svg" alt="">

@param <E> the {@link Flux} output type
@param clazz the target class to cast to

@return a casted {@link Flux}
Cast the current { @link Flux } produced type into a target produced type .