Пример #1
0
        public virtual string GetHtmlChangeDescription()
        {
            StringBuilder sb       = new StringBuilder();
            RootDetail    previous = (RootDetail)_navigateBackward;

            if (this.Change == ChangeType.None)
            {
                sb.Append("None");
            }

            if ((this.Change & ChangeType.Added) != 0)
            {
                AppendClauseHtml(sb, false, "Added");
            }

            if (((this.Change & ChangeType.RemovedBreaking) != 0) || ((this.Change & ChangeType.RemovedNonBreaking) != 0))
            {
                AppendClauseHtml(sb, ((this.Change & ChangeType.RemovedBreaking) != 0), "Removed");
            }

            if ((this.Change & ChangeType.AttributesChanged) != 0)
            {
                AppendClauseHtml(sb, false, "Attributes changed");
            }

            if ((this.Change & ChangeType.ImplementationChanged) != 0)
            {
                AppendClauseHtml(sb, false, "Implementation changed");
            }

            if ((this.Change & ChangeType.ContentChanged) != 0)
            {
                AppendClauseHtml(sb, ChangeTypeUtil.HasBreaking(this.Change), "Content changed");
            }

            if (((this.Change & ChangeType.ValueChangedBreaking) != 0) || ((this.Change & ChangeType.ValueChangedNonBreaking) != 0))
            {
                AppendClauseHtml(sb, ((this.Change & ChangeType.ValueChangedBreaking) != 0), "Value changed");
            }

            if (((this.Change & ChangeType.DeclarationChangedBreaking) != 0) || ((this.Change & ChangeType.DeclarationChangedNonBreaking) != 0))
            {
                AppendClauseHtml(sb, ((this.Change & ChangeType.DeclarationChangedBreaking) != 0), "Declaration changed");
            }

            if (((this.Change & ChangeType.VisibilityChangedBreaking) != 0) || ((this.Change & ChangeType.VisibilityChangedNonBreaking) != 0))
            {
                AppendClauseHtml(sb, ((this.Change & ChangeType.VisibilityChangedBreaking) != 0), VisibilityUtil.GetVisibilityChangeText(previous, this));
            }

            if (((this.Change & ChangeType.ObsoleteChangedBreaking) != 0) || ((this.Change & ChangeType.ObsoleteChangedNonBreaking) != 0))
            {
                AppendClauseHtml(sb, ((this.Change & ChangeType.ObsoleteChangedBreaking) != 0), ObsoleteUtil.GetObsoleteChangeText(previous, this));
            }

            if (((this.Change & ChangeType.MembersChangedBreaking) != 0) || ((this.Change & ChangeType.MembersChangedNonBreaking) != 0))
            {
                GetHtmlChangeDescriptionBriefMembers(sb);
            }

            return(sb.ToString());
        }
Пример #2
0
        public virtual string GetTextChangeDescription()
        {
            StringBuilder sb       = new StringBuilder();
            RootDetail    previous = (RootDetail)_navigateBackward;

            if ((this.Change & ChangeType.Added) != 0)
            {
                AppendClauseText(sb, "Added");
            }

            if (((this.Change & ChangeType.RemovedBreaking) != 0) || ((this.Change & ChangeType.RemovedNonBreaking) != 0))
            {
                AppendClauseText(sb, "Removed");
            }

            if ((this.Change & ChangeType.ContentChanged) != 0)
            {
                AppendClauseText(sb, "Content changed");
            }

            if ((this.Change & ChangeType.ValueChangedBreaking) != 0)
            {
                AppendClauseText(sb, "Value has a breaking change");
            }
            else if ((this.Change & ChangeType.ValueChangedNonBreaking) != 0)
            {
                AppendClauseText(sb, "Value has a non-breaking change");
            }

            if (((this.Change & ChangeType.DeclarationChangedBreaking) != 0) || ((this.Change & ChangeType.DeclarationChangedNonBreaking) != 0))
            {
                AppendClauseText(sb, "Declaration changed");
            }

            if (((this.Change & ChangeType.VisibilityChangedBreaking) != 0) || ((this.Change & ChangeType.VisibilityChangedNonBreaking) != 0))
            {
                AppendClauseText(sb, VisibilityUtil.GetVisibilityChangeText(previous, this));
            }

            if (((this.Change & ChangeType.ObsoleteChangedBreaking) != 0) || ((this.Change & ChangeType.ObsoleteChangedNonBreaking) != 0))
            {
                AppendClauseText(sb, ObsoleteUtil.GetObsoleteChangeText(previous, this));
            }

            if (((this.Change & ChangeType.MembersChangedBreaking) != 0) || ((this.Change & ChangeType.MembersChangedNonBreaking) != 0))
            {
                GetTextDescriptionBriefMembers(sb);
            }

            if ((this.Change & ChangeType.ImplementationChanged) != 0)
            {
                AppendClauseText(sb, "Implementation changed");
            }

            if ((this.Change & ChangeType.AttributesChanged) != 0)
            {
                AppendClauseText(sb, "Attributes changed");
            }

            return(sb.ToString());
        }