User Tools

Site Tools


adt_example

This is an old revision of the document!


StringList ADT

I want to give a simple example about creating abstract data types in Pelles C.

This example could be very much expanded. But I tried to leave it as simple as possible to show the principle case.

The user should see the ADT as a black box. He has not to know anything about internal structures nor the implementation of the ADT. All he knows and should use is the name of the ADT and its exported functions.

Therefore the implementor of an ADT writes an header file, the user may include.

In this example we will build a string list. We declare the ADT type name as:

adt_example.1415786505.txt.gz · Last modified: 2014/11/12 11:01 by czerny