You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@pivot.apache.org by Ajay Bhat <a....@gmail.com> on 2013/11/17 08:11:48 UTC

Getting keys from HashMap

Hi,

Is there any way to get the keys as a ArrayList from HashMap in
org.apache.pivot.collections.HashMap?

In java.util.TreeMap we would just use keySet() function. Is there anything
similar in Pivot?

Thanks,
Ajay Bhat

Re: Getting keys from HashMap

Posted by Sandro Martini <sa...@gmail.com>.
Hi,
this is the related issue: https://issues.apache.org/jira/browse/PIVOT-799
be free to put some comment/request/patch there ...

Note that there is even the package
org.apache.pivot.collections.adapter to transform Pivot Collections
to/from Java Collections.
Take a look and tell us if something is still missing.

Bye


2013/11/17 Roger Whitcomb <Ro...@rbwhitcomb.com>:
> Hi Ajay,
>    No there isn't such a method. Wouldn't be too hard to do if you want to tackle it. I believe there is an existing issue about adding methods to Pivot Collections to bring them more in line with the Java ones.
>
> ~Roger Whitcomb
>
> Sent from my iPhone
>
>> On Nov 16, 2013, at 11:11 PM, Ajay Bhat <a....@gmail.com> wrote:
>>
>> Hi,
>>
>> Is there any way to get the keys as a ArrayList from HashMap in org.apache.pivot.collections.HashMap?
>>
>> In java.util.TreeMap we would just use keySet() function. Is there anything similar in Pivot?
>>
>> Thanks,
>> Ajay Bhat

Re: Getting keys from HashMap

Posted by Roger Whitcomb <Ro...@rbwhitcomb.com>.
Hi Ajay,
   No there isn't such a method. Wouldn't be too hard to do if you want to tackle it. I believe there is an existing issue about adding methods to Pivot Collections to bring them more in line with the Java ones. 

~Roger Whitcomb

Sent from my iPhone

> On Nov 16, 2013, at 11:11 PM, Ajay Bhat <a....@gmail.com> wrote:
> 
> Hi,
> 
> Is there any way to get the keys as a ArrayList from HashMap in org.apache.pivot.collections.HashMap?
> 
> In java.util.TreeMap we would just use keySet() function. Is there anything similar in Pivot?
> 
> Thanks,
> Ajay Bhat