コード例 #1
0
        public bool Equals(object x, object y)
        {
            ObjectWithId xObject = x as ObjectWithId;
            ObjectWithId yObject = y as ObjectWithId;

            return(xObject.Id.Equals(yObject.Id));
        }
コード例 #2
0
 public ObjectWithId(ObjectWithId other)
 {
     m_id       = other.m_id;
     m_name     = other.m_name;
     m_iconPath = other.m_iconPath;
     m_icon     = other.m_icon;
 }
コード例 #3
0
        public int CompareTo(object obj)
        {
            ObjectWithId other = obj as ObjectWithId;

            return(m_id.CompareTo(other.m_id));
        }
コード例 #4
0
        public int GetHashCode(object obj)
        {
            ObjectWithId @object = obj as ObjectWithId;

            return(@object.Id.GetHashCode());
        }