Standard interface for containers?



 DEVELOP > c-Plus-Plus > Standard interface for containers?

LINK TO THIS PAGE  


rating :  0   |  0


  Page 1 of 1

1

 
Topic: DEVELOP > c-Plus-Plus
User: "saneman"
Date: 28 Jan 2008 04:52:47 AM
Object: Standard interface for containers?
C++ contains the following containers:
- Vector
- List
- Dequeue
- Queue
- Stack
- Map
- Set
- Bitset
Is there a single common interface for all these containers or do they
each implement their own interface?
.

User: "Michael DOUBEZ"

Title: Re: Standard interface for containers? 28 Jan 2008 05:06:49 AM
saneman a écrit :

C++ contains the following containers:

- Vector
- List
- Dequeue
- Queue
- Stack
- Map
- Set
- Bitset


Is there a single common interface for all these containers or do they
each implement their own interface?

They implement different concept ("Back insertion Container",
"Associative container" ...) to which correspond specific interface.
Please, refer to SGI STL for comprehensive reading.
http://www.sgi.com/tech/stl/
Michael
.
User: "saneman"

Title: Re: Standard interface for containers? 28 Jan 2008 06:18:30 AM
Michael DOUBEZ wrote:

saneman a écrit :

C++ contains the following containers:

- Vector
- List
- Dequeue
- Queue
- Stack
- Map
- Set
- Bitset


Is there a single common interface for all these containers or do they
each implement their own interface?


They implement different concept ("Back insertion Container",
"Associative container" ...) to which correspond specific interface.

Please, refer to SGI STL for comprehensive reading.
http://www.sgi.com/tech/stl/

Michael

Ok but in the C++ Standard it seems that there is some basic requirement
that all containers must fulfill. In section 23.1 table 65 these
requirements are listed.
So would it be correct to say that table 65 works as a basic interface
for associative containers and sequences (but not adaptors)?
Adaptors as I understand is a subset of sequences that not necessary
fulfill all container or sequence requirements.
.



  Page 1 of 1

1

 


Related Articles
 

NEWER

pg.1232     pg.940     pg.716     pg.544     pg.412     pg.311     pg.234     pg.175     pg.130     pg.96     pg.70     pg.50     pg.35     pg.24     pg.16     pg.10     pg.6     pg.3     pg.1

OLDER