MixinRefactoring.Member.Clone C# (CSharp) Method

Clone() public method

creates a copy of this member instance
public Clone ( bool needsOverrideKeywork = false ) : Member
needsOverrideKeywork bool when set, the copy /// will have an additional override keyword
return Member
        public Member Clone(bool needsOverrideKeywork = false)
        {
            var copy = CreateCopy();
            copy.Name = Name;
            copy.IsOverride = needsOverrideKeywork;
            copy.Documentation = Documentation; // both hold the same reference, check if this might become a problem
            // if this member will have an override keyword, it cannot be abstract
            copy.IsAbstract = !needsOverrideKeywork && IsAbstract;
            copy.IsInternal = IsInternal;
            return copy;
        }