java - Simple Set with only "contains" method -


I am looking for a simple set in Java that only provides the following functionality.

 set  add (string); Set contains (string s);   

There is no need to retrieve any elements of the set. I want to see what I have to do, to see whether the string is contained or not. Is there any such data structure in Java?

Edit: I know that I can use a set implementation like Hussett, etc. ... but I want a minimum data structure with only two methods listed above. / P>

EDIT2: Im has a memory constraint system.

Use, both of which have functionality, but this will not allow duplicates

Comments

Popular posts from this blog

wpf - ControlTemplate with changes for every class -

sonata admin - how to add ManyToOne property field in configureListfield in sonataAdmin -

sql - Return Function using Cursor -