Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What does this colon mean in this C# code?

Tags:

c#

inheritance

What does the : indicates in the class or interface definition in C#.

public interface IServer : IServerManager, ISimulation, ISiteEx
{
    /// <summary>
    /// Returns the highest game version that supported by this server.
    /// Higher versions aren't guaranteed to work perfect.
    /// </summary>
    Version MaxSupportedGameVersion { get; }

    /// <summary>
    /// Gets/sets the current server configuration.
    /// </summary>
    ServerConfiguration Configuration { get; set; }
}
like image 804
user979640 Avatar asked Oct 05 '11 03:10

user979640


1 Answers

: is used to indicate that the interface on the left side of the operator is implementing ( technically, the classes implementing the interface will give the implementation) the interfaces on the right.

: is used in the same way to indicate when a class is implementing one or more interfaces as well.

like image 136
manojlds Avatar answered Oct 06 '22 05:10

manojlds