Filtering and Transforming methods for Tables

410 views
Skip to first unread message

Ricardo Redder

unread,
Apr 7, 2011, 1:30:56 AM4/7/11
to guava-...@googlegroups.com
Hi,
O noticed that there are no methods filterXXX and transformXXX methods for the Table interface, so, a couple of questions about that:
  • Has it been suggested / rejected before? (I could not find any reference to that on the discussion list or among the issues)
  • I could thought of a few useful cases, however I'm not really familiar with Guava implementation details, so... is it plausible to implement using the "view" concept?
I thought of something that would be similar to Maps.filterXXX and Maps.transformXXX.

Regards,

--
Redder

Jared Levy

unread,
Apr 7, 2011, 2:08:48 AM4/7/11
to Ricardo Redder, guava-...@googlegroups.com
You're the first person to ask for a filtered or transformed Table. While they're feasible, it would take a lot of effort to implement them because the Table interfaces has many methods and views. 

To get an idea of what's involved, you can look over the implementation of filtered or transformed Maps in

The analogous Table implementation would be similar but longer since Table is a more complex interface than Map.


Ted Zlatanov

unread,
Apr 15, 2011, 11:20:20 AM4/15/11
to Jared Levy, Ricardo Redder, guava-...@googlegroups.com
On Wed, 6 Apr 2011 23:08:48 -0700 Jared Levy <jared....@gmail.com> wrote:

JL> You're the first person to ask for a filtered or transformed Table. While
JL> they're feasible, it would take a lot of effort to implement them because
JL> the Table interfaces has many methods and views.

JL> To get an idea of what's involved, you can look over the implementation of
JL> filtered or transformed Maps in
JL> http://code.google.com/p/guava-libraries/source/browse/trunk/src/com/google/common/collect/Maps.java

JL> The analogous Table implementation would be similar but longer since Table
JL> is a more complex interface than Map.

I'll second the request. Many cases where I use GlazedLists currently
would be easier with Tables, especially for sparse data sets.

Ted

Charles Fry

unread,
Apr 15, 2011, 11:34:33 AM4/15/11
to Ted Zlatanov, Jared Levy, Ricardo Redder, guava-...@googlegroups.com
Feel free to file a feature request:


Charles

Ted Zlatanov

unread,
Apr 15, 2011, 11:44:16 AM4/15/11
to Charles Fry, Jared Levy, Ricardo Redder, guava-...@googlegroups.com
On Fri, 15 Apr 2011 11:34:33 -0400 Charles Fry <f...@google.com> wrote:

CF> Feel free to file a feature request:
CF> http://code.google.com/p/guava-libraries/issues/entry

Done: http://code.google.com/p/guava-libraries/issues/detail?id=606

Thanks
Ted

koolsh...@gmail.com

unread,
Aug 18, 2013, 5:50:49 PM8/18/13
to guava-...@googlegroups.com
Its being couple of year since this post is made, just wondering if there is a way to implement filterXXX , I can find alternate to transformXXX in Tables class as Tables.transformValues

Thanks,
Shailesh

Rapolu Ramchandhar Reddy

unread,
Aug 29, 2013, 8:39:02 AM8/29/13
to guava-...@googlegroups.com
Hi All,

Do we have any navigableMap features in guava, where i have a set of records and it should process the results based on filter criteria and create Navigabletree.

Apologies to put this on a wrong , but close to what i want.

Regards
Ram
Reply all
Reply to author
Forward
0 new messages