Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 STL library like C++?
Index -> Programming, Java -> Java Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
MysticVegeta




PostPosted: Sat Nov 26, 2005 11:45 pm   Post subject: STL library like C++?

Is there a standard template library in Java like C++ because I prefered using that over arrays. (wtd's long tutorial)
Sponsor
Sponsor
Sponsor
sponsor
wtd




PostPosted: Sat Nov 26, 2005 11:50 pm   Post subject: (No subject)

There are certainly collections classes. Things like Vector, ArrayList, etc., and there are classes which contain static methods for manipulating these, but there is no direct equivalent to the STL in Java.

Templates in C++ behave differently than Java's generics.
MysticVegeta




PostPosted: Sun Nov 27, 2005 1:01 am   Post subject: (No subject)

are those better than using arrays though?, because i ammore experienced in arrays than STL
wtd




PostPosted: Sun Nov 27, 2005 1:22 am   Post subject: (No subject)

Depends. Do you need something that can grow? If so, then using one of these classes likely represents significantly less overhead than dealing with the expansion issue yourself.
Display posts from previous:   
   Index -> Programming, Java -> Java Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 4 Posts ]
Jump to:   


Style:  
Search: