You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@flink.apache.org by subash basnet <ya...@gmail.com> on 2016/04/11 15:42:37 UTC

Getting elements from DataStream

Hello all,

Getting certain number of elements from DataSet is possible as below:
*DataSet<Centroid> centroids = newDataSet.map(new
TupleCentroidConverter()).first(3);*

How could I get elements as above in DataStream
*DataStream<Centroid> centroids = newDataStream.map(new
TupleCentroidConverter()).???*


Best Regards,
Subash Basnet

Re: Getting elements from DataStream

Posted by Stephan Ewen <se...@apache.org>.
Hi!

The equivalent does not yet exist on DataStream.

Stephan


On Mon, Apr 11, 2016 at 3:42 PM, subash basnet <ya...@gmail.com> wrote:

> Hello all,
>
> Getting certain number of elements from DataSet is possible as below:
> *DataSet<Centroid> centroids = newDataSet.map(new
> TupleCentroidConverter()).first(3);*
>
> How could I get elements as above in DataStream
> *DataStream<Centroid> centroids = newDataStream.map(new
> TupleCentroidConverter()).???*
>
>
> Best Regards,
> Subash Basnet
>