Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > Index-based datastructure

Reply
Thread Tools

Index-based datastructure

 
 
Sharp
Guest
Posts: n/a
 
      03-14-2005
Hi

Is it fair to say that besides Vector and primitive based arrays (int[]
etc..), the ArrayList is the only datastructure that is part of the Java API
that is index based?

Cheers
Sharp




 
Reply With Quote
 
 
 
 
Chris Uppal
Guest
Posts: n/a
 
      03-14-2005
Sharp wrote:

> Is it fair to say that besides Vector and primitive based arrays (int[]
> etc..), the ArrayList is the only datastructure that is part of the Java
> API that is index based?


Well, there's also String (and the other classes that implement CharSequence).

And don't forget that you can have arrays of objects too

One could argue that /all/ implementations of java.util.List are index-based
(depending on what you mean by that term, of course).

One could argue that java.nio.XxxxBuffer are all index-based, but you might not
necessarily want to call them "datastructures" (depending on what you mean by
that term, of course).

Implementations of javax.swing.table.TableModel are clearly index-based. I
imagine that one could find many other similar examples in the areas of
graphics and UI.

There is at least one new index-based container in J5 --
java.util.concurrent.CopyOnWriteArrayList.

And so on...

-- chris



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
newbie: datastructure `dictionary' question jason Python 4 09-09-2006 06:51 PM
What datastructure to use to store nodes/locations I've visited 6tc1@qlink.queensu.ca Java 3 06-23-2005 02:28 AM
Set DataStructure Anony! Java 2 08-13-2004 02:32 AM
Datastructure and Algorithms Prateek Basu C Programming 4 01-24-2004 10:37 AM
Datastructure design Santosh C Programming 6 11-20-2003 07:26 AM



Advertisments