// slist.h: interface for the slist class. // ////////////////////////////////////////////////////////////////////// #if !defined(AFX_SLIST_H__E6BEA101_41AF_11D2_B2B2_0040052DB186__INCLUDED_) #define AFX_SLIST_H__E6BEA101_41AF_11D2_B2B2_0040052DB186__INCLUDED_ #if _MSC_VER >= 1000 #pragma once #endif // _MSC_VER >= 1000 #include "list.h" // Sorted List (slist) is the same as list, we just redefine // the insert() function to make sure it inserts in order. // // We also redefine the find function so that it starts from currentPos // and searches in the correct direction class slist : public list { public: void insertAtHead(String name); virtual void insert(String name); //inserts name in its proper place. slist(); virtual ~slist(); private: void insertRight(String name); void insertLeft(String name); }; #endif // !defined(AFX_SLIST_H__E6BEA101_41AF_11D2_B2B2_0040052DB186__INCLUDED_)