Beispiel #1
0
 /// <summary>
 ///   Indicates whether the current object is equal to another object of the same type.
 /// </summary>
 /// <returns>
 ///   true if the current object is equal to the <paramref name="other"/> parameter;
 ///   otherwise, false.
 /// </returns>
 /// <param name="other">An object to compare with this object.</param>
 public virtual bool Equals(PooledObject other)
 {
     if (ReferenceEquals(null, other))
     {
         return(false);
     }
     if (ReferenceEquals(this, other))
     {
         return(true);
     }
     return(PooledObjectInfo.Equals(other.PooledObjectInfo));
 }
Beispiel #2
0
 /// <summary>
 ///   Returns a string that represents the current object.
 /// </summary>
 /// <returns>A string that represents the current object.</returns>
 public override string ToString() => PooledObjectInfo.ToString();
Beispiel #3
0
 /// <summary>
 ///   Serves as a hash function for a particular type.
 /// </summary>
 /// <returns>A hash code for the current <see cref="PooledObject"/>.</returns>
 public override int GetHashCode() => PooledObjectInfo.GetHashCode();