System.Threading.CompressedStack.CompressedStack.Equals C# (CSharp) Method

Equals() private method

private Equals ( CompressedStack cs ) : bool
cs CompressedStack
return bool
		internal bool Equals (CompressedStack cs)
		{
			if (IsEmpty ())
				return cs.IsEmpty ();
			if (cs.IsEmpty ())
				return false;
			if (_list.Count != cs._list.Count)
				return false;

			for (int i=0; i < _list.Count; i++) {
				SecurityFrame sf1 = (SecurityFrame) _list [i];
				SecurityFrame sf2 = (SecurityFrame) cs._list [i];
				if (!sf1.Equals (sf2))
					return false;
			}
			return true;
		}