Пример #1
0
 /// <summary>
 /// Equals
 /// </summary>
 /// <param name="item">Other item</param>
 /// <returns>Result</returns>
 public bool Equals(ScriptReferenceMeta item)
 {
     if (item == null)
     {
         return(false);
     }
     return(Src.Equals(item.Src) && DebugSrc.Equals(item.DebugSrc));
 }
Пример #2
0
        /// <summary>
        /// Determines value equality.
        /// </summary>
        /// <param name="other">The other object to compare against.</param>
        /// <returns>True if the objects are equal.</returns>
        protected virtual bool IsEqual(DefaultPath <V, E> other)
        {
            bool result = Src.Equals(other.Src) &&
                          Dst.Equals(other.Dst) &&
                          edges.SequenceEqual(other.edges) &&
                          // TODO: This is clunky, is there a better way?
                          (other.Cost?.Equals(Cost) ?? Cost is null);

            return(result);
        }
Пример #3
0
 /// <summary>
 /// Determines value equality.
 /// </summary>
 /// <param name="other">The other object to compare against.</param>
 /// <returns>True if the objects are equal.</returns>
 /// TODO: Should this be virtual?
 protected virtual bool IsEqual(AbstractEdge<V> other) => Src.Equals(other.Src) && Dst.Equals(other.Dst);
Пример #4
0
 private void ChangeUrl()
 {
     Src = Src.Equals(one) ? two : one;
 }
Пример #5
0
 protected bool Equals(MoveAction other)
 {
     return(Src.Equals(other.Src) && Dst.Equals(other.Dst));
 }