You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@flink.apache.org by Malte Schwarzer <ms...@mieo.de> on 2015/01/23 11:27:12 UTC

How to use Tuple in ListValue?

Hello,

is it possible to use some how Tuple objects (e.g. Tuple2<String, Integer>)
in a ListValue? Even if Tuple is serializable, it does not implement the
Value interface. Therefore ListValue<Tuple2> is it working.

Is there any work-around? I want to use something like "Tuple2<String,
ListValue<Tuple2<String, Integer>>>³ as dataset.

Cheers
Malte



Re: How to use Tuple in ListValue?

Posted by Stefano Bortoli <s....@gmail.com>.
what I did was to implement ListValue in a MyListValue object, then you can
do pretty much what you want. :-)

saluti,
Stefano

2015-01-23 11:29 GMT+01:00 Robert Metzger <rm...@apache.org>:

> Hi,
>
> I think you can just use a java collection for the Tuple2's. (Starting
> from Flink 0.8.0)
>
> Robert.
>
> On Fri, Jan 23, 2015 at 11:27 AM, Malte Schwarzer <ms...@mieo.de> wrote:
>
>> Hello,
>>
>> is it possible to use some how Tuple objects (e.g. Tuple2<String,
>> Integer>) in a ListValue? Even if Tuple is serializable, it does not
>> implement the Value interface. Therefore ListValue<Tuple2> is it working.
>>
>> Is there any work-around? I want to use something like "Tuple2<String,
>> ListValue<Tuple2<String, Integer>>>“ as dataset.
>>
>> Cheers
>> Malte
>>
>
>

Re: How to use Tuple in ListValue?

Posted by Robert Metzger <rm...@apache.org>.
Hi,

I think you can just use a java collection for the Tuple2's. (Starting from
Flink 0.8.0)

Robert.

On Fri, Jan 23, 2015 at 11:27 AM, Malte Schwarzer <ms...@mieo.de> wrote:

> Hello,
>
> is it possible to use some how Tuple objects (e.g. Tuple2<String,
> Integer>) in a ListValue? Even if Tuple is serializable, it does not
> implement the Value interface. Therefore ListValue<Tuple2> is it working.
>
> Is there any work-around? I want to use something like "Tuple2<String,
> ListValue<Tuple2<String, Integer>>>“ as dataset.
>
> Cheers
> Malte
>