NArrange.Core.Configuration.TabConfiguration.Clone C# (CSharp) Method

Clone() public method

Creates a clone of this instance.
public Clone ( ) : object
return object
        public object Clone()
        {
            TabConfiguration clone = new TabConfiguration();

            clone._tabStyle = _tabStyle;
            clone._spacesPerTab = _spacesPerTab;

            return clone;
        }

Usage Example

Ejemplo n.º 1
0
        /// <summary>
        /// Creates a clone of this instance.
        /// </summary>
        /// <returns>
        /// A new object that is a copy of this instance.
        /// </returns>
        public object Clone()
        {
            FormattingConfiguration clone = new FormattingConfiguration();

            if (_closingComments != null)
            {
                clone._closingComments = _closingComments.Clone() as ClosingCommentConfiguration;
            }

            if (_regions != null)
            {
                clone._regions = _regions.Clone() as RegionFormatConfiguration;
            }

            if (_tabs != null)
            {
                clone._tabs = _tabs.Clone() as TabConfiguration;
            }

            if (_lineSpacing != null)
            {
                clone._lineSpacing = _lineSpacing.Clone() as LineSpacingConfiguration;
            }

            if (_usings != null)
            {
                clone._usings = _usings.Clone() as UsingConfiguration;
            }

            return(clone);
        }
All Usage Examples Of NArrange.Core.Configuration.TabConfiguration::Clone