コード例 #1
0
ファイル: BanCommand.cs プロジェクト: KarlOfDuty/SCPDiscord
        public override int GetHashCode()
        {
            int hash = 1;

            if (ChannelID != 0UL)
            {
                hash ^= ChannelID.GetHashCode();
            }
            if (SteamID.Length != 0)
            {
                hash ^= SteamID.GetHashCode();
            }
            if (Duration.Length != 0)
            {
                hash ^= Duration.GetHashCode();
            }
            if (Reason.Length != 0)
            {
                hash ^= Reason.GetHashCode();
            }
            if (AdminTag.Length != 0)
            {
                hash ^= AdminTag.GetHashCode();
            }
            if (_unknownFields != null)
            {
                hash ^= _unknownFields.GetHashCode();
            }
            return(hash);
        }
コード例 #2
0
        public override int GetHashCode()
        {
            int hash = 1;

            if (ChannelID != 0UL)
            {
                hash ^= ChannelID.GetHashCode();
            }
            if (DiscordID != 0UL)
            {
                hash ^= DiscordID.GetHashCode();
            }
            if (SteamID != 0UL)
            {
                hash ^= SteamID.GetHashCode();
            }
            if (DiscordTag.Length != 0)
            {
                hash ^= DiscordTag.GetHashCode();
            }
            if (_unknownFields != null)
            {
                hash ^= _unknownFields.GetHashCode();
            }
            return(hash);
        }
コード例 #3
0
ファイル: ChatMessage.cs プロジェクト: KarlOfDuty/SCPDiscord
        public override int GetHashCode()
        {
            int hash = 1;

            if (ChannelID != 0UL)
            {
                hash ^= ChannelID.GetHashCode();
            }
            if (Content.Length != 0)
            {
                hash ^= Content.GetHashCode();
            }
            if (_unknownFields != null)
            {
                hash ^= _unknownFields.GetHashCode();
            }
            return(hash);
        }
コード例 #4
0
 /// <summary>
 /// Fungiert als die Standardhashfunktion.
 /// Acts as the default hash function.
 /// </summary>
 /// <returns>
 /// Ein Hashcode für das aktuelle Objekt.
 /// A hash code for the current object.
 /// </returns>
 public override int GetHashCode()
 {
     return(1213502048 + ChannelID.GetHashCode());
 }