protected override void PerformDeepClone(object clone) { base.PerformDeepClone(clone); var clonedEntity = (Member)clone; //need to manually clone this since it's not settable clonedEntity._contentType = (IMemberType)ContentType.DeepClone(); }
public override object DeepClone() { var clone = (Content)base.DeepClone(); //turn off change tracking clone.DisableChangeTracking(); //need to manually clone this since it's not settable clone._contentType = (IContentType)ContentType.DeepClone(); //this shouldn't really be needed since we're not tracking clone.ResetDirtyProperties(false); //re-enable tracking clone.EnableChangeTracking(); return(clone); }