Results 1 to 2 of 2

Thread: Overriding Abstract Methods

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Jan 2005
    Location
    Christchurch, NZ
    Posts
    18

    Overriding Abstract Methods

    Hi

    I have create a class that inherits from an abstract class.
    This class has a number of abstract methods in it.
    I do not want to override all of the abstract methods.

    Is there any way that I can get around this.

    Cheers

  2. #2
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,221

    Re: Overriding Abstract Methods

    Have you read the help topic on abstract methods?
    An abstract method declaration introduces a new virtual method but does not provide an implementation of that method. Instead, non-abstract derived classes are required to provide their own implementation by overriding that method.
    You can make the method body empty but that is a hack. If you don't want to provide the functionality that the base class demands then you shouldn't be inheriting from that base class.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width