mirror of
https://github.com/ClassiCube/MCGalaxy.git
synced 2025-09-22 12:05:51 -04:00
Code style cleanup.
This commit is contained in:
parent
549058756f
commit
20932c59ac
@ -36,74 +36,32 @@ namespace Sharkbite.Irc
|
|||||||
private readonly string hostName;
|
private readonly string hostName;
|
||||||
private static readonly UserInfo EmptyInstance = new UserInfo();
|
private static readonly UserInfo EmptyInstance = new UserInfo();
|
||||||
|
|
||||||
/// <summary>
|
/// <summary> Creates an empty instance </summary>
|
||||||
/// Creat an empty instance
|
private UserInfo() {
|
||||||
/// </summary>
|
nickName = ""; userName = ""; hostName = "";
|
||||||
private UserInfo()
|
|
||||||
{
|
|
||||||
nickName = "";
|
|
||||||
userName = "";
|
|
||||||
hostName = "";
|
|
||||||
}
|
|
||||||
/// <summary>
|
|
||||||
/// Create a new UserInfo and set all its values.
|
|
||||||
/// </summary>
|
|
||||||
public UserInfo(string nick, string name, string host)
|
|
||||||
{
|
|
||||||
nickName = nick;
|
|
||||||
userName = name;
|
|
||||||
hostName = host;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary> Create a new UserInfo and set all its values. </summary>
|
||||||
/// An IRC user's nick name.
|
public UserInfo(string nick, string name, string host) {
|
||||||
/// </summary>
|
nickName = nick; userName = name; hostName = host;
|
||||||
public string Nick
|
|
||||||
{
|
|
||||||
get
|
|
||||||
{
|
|
||||||
return nickName;
|
|
||||||
}
|
}
|
||||||
}
|
|
||||||
/// <summary>
|
/// <summary> An IRC user's nick name. </summary>
|
||||||
/// An IRC user's system username.
|
public string Nick { get { return nickName; } }
|
||||||
/// </summary>
|
|
||||||
public string User
|
/// <summary> An IRC user's system username. </summary>
|
||||||
{
|
public string User { get { return userName; } }
|
||||||
get
|
|
||||||
{
|
/// <summary> The hostname of the IRC user's machine. </summary>
|
||||||
return userName;
|
public string Hostname { get { return hostName; } }
|
||||||
}
|
|
||||||
}
|
/// <summary> A singleton blank instance of UserInfo used when an instance is required
|
||||||
/// <summary>
|
|
||||||
/// The hostname of the IRC user's machine.
|
|
||||||
/// </summary>
|
|
||||||
public string Hostname
|
|
||||||
{
|
|
||||||
get
|
|
||||||
{
|
|
||||||
return hostName;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/// <summary>
|
|
||||||
/// A singleton blank instance of UserInfo used when an instance is required
|
|
||||||
/// by a method signature but no infomation is available, e.g. the last reply
|
/// by a method signature but no infomation is available, e.g. the last reply
|
||||||
/// from a Who request.
|
/// from a Who request. </summary>
|
||||||
/// </summary>
|
public static UserInfo Empty { get { return EmptyInstance; } }
|
||||||
public static UserInfo Empty
|
|
||||||
{
|
|
||||||
get
|
|
||||||
{
|
|
||||||
return EmptyInstance;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary> A string representation of this object which shows all its values. </summary>
|
||||||
/// A string representation of this object which
|
public override string ToString() {
|
||||||
/// shows all its values.
|
|
||||||
/// </summary>
|
|
||||||
public override string ToString()
|
|
||||||
{
|
|
||||||
return string.Format("Nick={0} User={1} Host={2}", Nick, User, Hostname );
|
return string.Format("Nick={0} User={1} Host={2}", Nick, User, Hostname );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user