Thread: please help

  1. #1
    Registered User
    Join Date
    Sep 2001
    Posts
    3

    please help

    hi

    what does ADT stand for?

    what 2 things should an ADT description include?

    what would be the specifications for a Clock ADT?

    THNKS

  2. #2
    Registered User
    Join Date
    Sep 2001
    Posts
    156

    please help

    Without any reference I'll say Access Developer's Toolkit which is put out by Microsoft. But from what you're asking I think I'm missing the mark.


    dang

  3. #3
    Skunkmeister Stoned_Coder's Avatar
    Join Date
    Aug 2001
    Posts
    2,572
    ADT

    Abstract Data Type.

    read a little about PURE virtual functions and you will begin to understand adt's.
    Free the weed!! Class B to class C is not good enough!!
    And the FAQ is here :- http://faq.cprogramming.com/cgi-bin/smartfaq.cgi

  4. #4
    Toaster Zach L.'s Avatar
    Join Date
    Aug 2001
    Posts
    2,686
    Perhaps what you are looking for is an abstract data type. These are base classes with pure virtual functions, and cannot be instantiated. Instead, they are used as base classes for inheritance.

    Here is an example:

    Code:
    class Clock
    {
    public:
        Clock {}
        virtual void tick() = 0; // This should have no definition.
    };
    Pure virtual functions (ones with '= 0' and no definition) must be overwritten in the derived classes. For example:

    Code:
    class Watch : public Clock
    {
    public:
        Watch() {}
        void tick() { /* Do something */ }
    };
    Now you could create an instance of the Watch class.
    The word rap as it applies to music is the result of a peculiar phonological rule which has stripped the word of its initial voiceless velar stop.

  5. #5
    Hamster without a wheel iain's Avatar
    Join Date
    Aug 2001
    Posts
    1,385
    Abstract Data Type
    Active Data Type
    Access Development Toolkit

    information supplied by case (see my sig)
    Monday - what a way to spend a seventh of your life

Popular pages Recent additions subscribe to a feed