Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ Equals()

override bool System.MulticastDelegate.Equals ( [NotNullWhen(true)] object? obj)
inlinesealed

Definition at line 51 of file MulticastDelegate.cs.

52 {
53 if (obj == null)
54 {
55 return false;
56 }
57 if (this == obj)
58 {
59 return true;
60 }
61 if (!Delegate.InternalEqualTypes(this, obj))
62 {
63 return false;
64 }
66 if (_invocationCount != (IntPtr)0)
67 {
69 {
71 {
72 if (!multicastDelegate.IsUnmanagedFunctionPtr())
73 {
74 return false;
75 }
76 return Delegate.CompareUnmanagedFunctionPtrs(this, multicastDelegate);
77 }
78 if (multicastDelegate._invocationList is Delegate)
79 {
80 return Equals(multicastDelegate._invocationList);
81 }
82 return base.Equals(obj);
83 }
85 {
86 return @delegate.Equals(obj);
87 }
89 }
91 {
92 if (!_invocationList.Equals(multicastDelegate._invocationList))
93 {
94 return false;
95 }
96 return base.Equals((object?)multicastDelegate);
97 }
98 if (multicastDelegate._invocationList is Delegate)
99 {
100 return Equals(multicastDelegate._invocationList);
101 }
102 return base.Equals((object?)multicastDelegate);
103 }
MulticastDelegate(object target, string method)
override bool Equals([NotNullWhen(true)] object? obj)
bool InvocationListEquals(MulticastDelegate d)

References System.MulticastDelegate._invocationCount, System.MulticastDelegate._invocationList, System.Delegate.CompareUnmanagedFunctionPtrs(), System.Runtime.Serialization.Dictionary, System.MulticastDelegate.Equals(), System.Delegate.InternalEqualTypes(), System.MulticastDelegate.InvocationListEquals(), System.MulticastDelegate.InvocationListLogicallyNull(), System.MulticastDelegate.IsUnmanagedFunctionPtr(), and System.obj.

Referenced by System.MulticastDelegate.EqualInvocationLists(), System.MulticastDelegate.Equals(), and System.MulticastDelegate.RemoveImpl().