Interface overloading

Posted on 2009-12-22
Last Modified: 2013-11-07

I was asked in an interview about interface overloading in .net.

Could you please tell me an site to explain this concept
Question by:KaranGupta
    1 Comment
    LVL 2

    Accepted Solution

    Hi KaranGupta,

    Of course, interface can also have overloaded members. Just see the below code for instance..
    interface ITest
       void F();                     // F()
       void F(int x);                  // F(int)
       void F(ref int x);            // F(ref int)
       void F(int x, int y);         // F(int, int)
       int F(string s);               // F(string)
       int F(int x);                  // F(int)         error
       void F(string[] a);            // F(string[])
       void F(params string[] a);      // F(string[])      error

    You can read the full story at the following location

    Kindly add your comment if it was an ample solution for your doubt.

    Abel Allen

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    What Security Threats Are You Missing?

    Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

    Suggested Solutions

    Welcome my friends to the second instalment and follow-up to our Minify and Concatenate Your Scripts and Stylesheets (…
    Many of us here at EE write code. Many of us write exceptional code; just as many of us write exception-prone code. As we all should know, exceptions are a mechanism for handling errors which are typically out of our control. From database errors, t…
    Need more eyes on your posted question? Go ahead and follow the quick steps in this video to learn how to Request Attention to your question. *Log into your Experts Exchange account *Find the question you want to Request Attention for *Go to the e…
    Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

    737 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    22 Experts available now in Live!

    Get 1:1 Help Now