Example #1
0
        private static int InternalHistorySort(VoteProfileEntry a, VoteProfileEntry b)
        {
            if (a == b)
            {
                return(0);
            }

            if (a == null)
            {
                return(1);
            }

            if (b == null)
            {
                return(-1);
            }

            if (a.VoteTime > b.VoteTime)
            {
                return(-1);
            }

            if (a.VoteTime < b.VoteTime)
            {
                return(1);
            }

            return(0);
        }
Example #2
0
		private static int InternalHistorySort(VoteProfileEntry a, VoteProfileEntry b)
		{
			if (a == b)
			{
				return 0;
			}

			if (a == null)
			{
				return 1;
			}

			if (b == null)
			{
				return -1;
			}

			if (a.VoteTime > b.VoteTime)
			{
				return -1;
			}

			if (a.VoteTime < b.VoteTime)
			{
				return 1;
			}

			return 0;
		}