CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2

Thread: Implements ?

  1. #1
    Guest

    Implements ?

    Hi,
    what's the purpose of the sentence 'implements'
    when you are implementing classes inherit.

    thanks.


  2. #2
    Join Date
    May 1999
    Location
    Oxford UK
    Posts
    1,459

    Re: Implements ?

    Hi

    The 'implements' keyword does not mean 'inheritance' in VB (well, it inherits Interfaces).

    Implements is used to provide PolyMorphism in VB - this means that an Object (class/form/control) can be accessed using different interfaces.

    Take a look at the VBCodeLibrary source-code at http://www.codeguru.com/vb/articles/1634.shtml for an example of the Implements keyword/methodology.

    You'll see a base-class/interfaces called IDataObject which other classes 'implement' so that they can be called using that interface.



    Chris Eastwood

    CodeGuru - the website for developers
    http://www.codeguru.com/vb

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

Featured