protected virtual string SerializeGetWhatChangedValue(ChangeType changeType) { if (((changeType & ChangeType.DeclarationChangedNonBreaking) != 0) || ((changeType & ChangeType.DeclarationChangedBreaking) != 0) || (changeType == ChangeType.Added) || (changeType == ChangeType.ValueChangedBreaking) || (changeType == ChangeType.ValueChangedNonBreaking)) { return(ToString()); } else if ((this is IHaveVisibility) && (((changeType & ChangeType.VisibilityChangedBreaking) != 0) || ((changeType & ChangeType.VisibilityChangedNonBreaking) != 0))) { IHaveVisibility hv = (IHaveVisibility)this; return(hv.Visibility.ToString().ToLower()); } else if ((this is IHaveObsoleteAttribute) && (((changeType & ChangeType.ObsoleteChangedBreaking) != 0) || ((changeType & ChangeType.ObsoleteChangedNonBreaking) != 0))) { IHaveObsoleteAttribute hv = (IHaveObsoleteAttribute)this; return(ObsoleteUtil.GetObsoleteString(hv.ObsoleteAttribute)); } else { return(null); } }
protected virtual ChangeType CompareObsoleteStatus(ICanCompare previous, bool suppressBreakingChanges) { MemberDetail other = (MemberDetail)previous; return(ObsoleteUtil.GetObsoleteChange(other._obsoleteAttribute, _obsoleteAttribute, suppressBreakingChanges)); }
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()); }
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()); }