//----------------------------------------------------------------------
//  SPECIFICATION FILE (namedstk.h)
//  This module exports an ADT for a stack of integer values.
//  The maximum stack depth is MAX_DEPTH, an unspecified value.
//  NamedStack is derived from the IntStack class (in the UStack module).
//  IntStack is a public base class of NamedStack, so public
//  operations of IntStack are also public operations of NamedStack.
//----------------------------------------------------------------------
#include "ustack.h"

// DOMAIN: A NamedStack instance is a collection of integer values
//         along with a character string naming the stack

class NamedStack : public IntStack {
public:
    void WriteName() const;
        // POST: Name of stack has been output

    NamedStack( /* in */ const char* stackName );
        // PRE:  Assigned(stackName)
        // POST: Created(stack)  &&  stack == <>
        //    && Stack's name is stackName

    NamedStack( const NamedStack& otherStk );
        // POST: Created(stack)  &&  stack == otherStk

    ~NamedStack();
        // POST: NOT Created(stack)
private:
    char* stkName;
};


