public object this[int index] { get { WeakRefObject weakRef = InnerList[index] as WeakRefObject; if ((weakRef != null) && (weakRef.IsAlive)) { return(weakRef.Target); } return(null); } set { InnerList[index] = CreateWeakRefObject(value); } }
public object this[int index] { get { WeakRefObject obj2 = this.InnerList[index] as WeakRefObject; if ((obj2 != null) && obj2.IsAlive) { return(obj2.Target); } return(null); } set { this.InnerList[index] = this.CreateWeakRefObject(value); } }
public override bool Equals(object obj) { WeakRefObject weakRefObject = obj as WeakRefObject; if (weakRefObject == this) { return(true); } if (weakRefObject == null) { return(false); } if (weakRefObject.Target != Target && (Target == null || !Target.Equals(weakRefObject.Target))) { return(false); } return(true); }
public override bool Equals(object obj) { WeakRefObject other = obj as WeakRefObject; if (other == this) { return(true); } if (other == null) { return(false); } if (other.Target != this.Target) { if (this.Target == null || !this.Target.Equals(other.Target)) { return(false); } } return(true); }