Reputation: 41841
What is the difference between Collections and "Stored Collections" in Java? and why they are called "Stored"?
Upvotes: 1
Views: 866
Reputation: 91881
Stored Collections are not a standard java concept. I assume you are referring to the Oracle concept. That link describes some of the differences, but the upshot is that the database is using (abusing - because it violates the contract) the Collection
interface in order to provide storage in a database. Standard java Collections are in-memory only objects, and storage and retrieval are done with separate APIs.
Upvotes: 3
Reputation: 17525
Collection in general describe an object which can handle a number of other objects. Stored collections is a term used to describe collections stored in a database (hence the term).
Upvotes: 2
Reputation: 9311
I've never heard about "stored collections" in the default Java API. There are stored collections in certain database-related libraries, however. For example, the Java libraries for Oracle have so called "stored collections", which are basically nothing else than collections that can be persisted using an Oracle database.
Upvotes: 3