Esempio n. 1
0
        public override int GetHashCode()
        {
            int hash = 1;

            if (Id != 0)
            {
                hash ^= Id.GetHashCode();
            }
            if (UserId != 0L)
            {
                hash ^= UserId.GetHashCode();
            }
            if (SessionId != 0L)
            {
                hash ^= SessionId.GetHashCode();
            }
            if (ServiceId0 != 0)
            {
                hash ^= ServiceId0.GetHashCode();
            }
            if (ServiceId1 != 0)
            {
                hash ^= ServiceId1.GetHashCode();
            }
            if (Token.Length != 0)
            {
                hash ^= Token.GetHashCode();
            }
            if (TokenExpiredTime != 0L)
            {
                hash ^= TokenExpiredTime.GetHashCode();
            }
            return(hash);
        }
Esempio n. 2
0
        /// <summary>
        /// Compares two instances of this object.
        /// </summary>
        /// <param name="ServiceId1">An user identification.</param>
        /// <param name="ServiceId2">Another user identification.</param>
        /// <returns>true|false</returns>
        public static Boolean operator >=(Service_Id ServiceId1,
                                          Service_Id ServiceId2)

        => ServiceId1.CompareTo(ServiceId2) >= 0;
Esempio n. 3
0
        /// <summary>
        /// Compares two instances of this object.
        /// </summary>
        /// <param name="ServiceId1">An user identification.</param>
        /// <param name="ServiceId2">Another user identification.</param>
        /// <returns>true|false</returns>
        public static Boolean operator !=(Service_Id ServiceId1,
                                          Service_Id ServiceId2)

        => !ServiceId1.Equals(ServiceId2);