public bool Equals(ShapeableSpecified other) { if (ReferenceEquals(null, other)) { return(false); } if (ReferenceEquals(this, other)) { return(true); } return(Equals(other._dynamicMembers, _dynamicMembers) && Equals(other._specification, _specification)); }
public object Clone() { // cloning: property data gets serialized to / fro, method delegates get cloned var clone = new ShapeableSpecified(); _memberNames.ForEach(mn => clone._memberNames.Add(mn)); _specification.ForEach(sp => clone._specification.Add(sp.Key, sp.Value)); if (null != _initializer) { clone._initializer = (ThisAction)_initializer.Clone(); } MemberDictionaryClone(_dynamicMembers, clone._dynamicMembers); clone._nestedTargets.AddRange(_nestedTargets); return(clone); }