One Class implements two Interfaces which have the same name method : Interface « Class « VB.Net

VB.Net
1. 2D
2. Application
3. Class
4. Data Structure
5. Database ADO.net
6. Development
7. Event
8. File Directory
9. Generics
10. GUI
11. Language Basics
12. Network Remote
13. Thread
14. Windows System
15. XML
Microsoft Office Word 2007 Tutorial
Java
Java Tutorial
Java Source Code / Java Documentation
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
C# / C Sharp
C# / CSharp Tutorial
ASP.Net
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
PHP
Python
SQL Server / T-SQL
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net Tutorial
VB.Net » Class » InterfaceScreenshots 
One Class implements two Interfaces which have the same name method
One Class implements two Interfaces which have the same name method

Imports System
Imports System.Data
Imports System.Collections

public class MainClass
   Shared Sub Main()
        Dim As New Class1()
        Dim i2 As MySecondInterface
        c.CommonFunction()
        i2 = c
        i2.CommonFunction()
   End Sub
End Class


Interface MyFirstInterface
    Sub UniqueFunction()
    Sub CommonFunction()
End Interface

Interface MySecondInterface
    Sub SecondUniqueFunction()
    Sub CommonFunction()
End Interface

Public Class Class1
    Implements MyFirstInterface
    Implements MySecondInterface

    Sub UniqueFunction() Implements MyFirstInterface.UniqueFunction

    End Sub

    Sub SecondUniqueFunction() Implements MySecondInterface.SecondUniqueFunction

    End Sub

    Sub CommonFunction() Implements MyFirstInterface.CommonFunction
        Console.WriteLine("Common Function on first interface")
    End Sub

    Sub CommonFunctionSecondInterface() Implements MySecondInterface.CommonFunction
        Console.WriteLine("Common function on second interface")
    End Sub

End Class

           
       
Related examples in the same category
1. Interface inherits interfaceInterface inherits interface
2. Class implements two interfaces
3. Implements an InterfaceImplements an Interface
4. Implement an InterfaceImplement an Interface
5. Define and use Interface AgeDefine and use Interface Age
6. Interface Inherits another InterfaceInterface Inherits another Interface
7. Define and use InterfaceDefine and use Interface
8. Implements Two InterfacesImplements Two Interfaces
9. Generic Class and InterfaceGeneric Class and Interface
w__w___w___.___ja__v_a__2_s__.__c_om___ | Contact Us
Copyright 2003 - 08 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.