1
0
mirror of https://github.com/ncblakely/GiantsTools synced 2024-11-23 06:35:37 +01:00
GiantsTools/Giants.DataContract/Contracts/V1/ServerInfoWithHostAddress.cs
2020-09-05 22:22:23 -07:00

27 lines
709 B
C#

namespace Giants.DataContract.V1
{
using System;
using System.ComponentModel.DataAnnotations;
public class ServerInfoWithHostAddress : ServerInfo
{
[Required]
public string HostIpAddress { get; set; }
public override bool Equals(object obj)
{
return obj is ServerInfoWithHostAddress address &&
base.Equals(obj) &&
this.HostIpAddress == address.HostIpAddress;
}
public override int GetHashCode()
{
HashCode hash = new HashCode();
hash.Add(base.GetHashCode());
hash.Add(this.HostIpAddress);
return hash.ToHashCode();
}
}
}