@@ -9,7 +9,7 @@ namespace AngleSharp.Xml
9
9
/// AutoSelectedMarkupFormatter class to select the proper MarkupFormatter
10
10
/// implementation depending on the used document type.
11
11
/// </summary>
12
- public sealed class AutoSelectedMarkupFormatter : IMarkupFormatter
12
+ public class AutoSelectedMarkupFormatter : IMarkupFormatter
13
13
{
14
14
#region Fields
15
15
@@ -60,86 +60,46 @@ private IMarkupFormatter ChildFormatter
60
60
61
61
#region Methods
62
62
63
- /// <summary>
64
- /// Formats an attribute specified by the argument.
65
- /// </summary>
66
- /// <param name="attribute">The attribute to serialize.</param>
67
- /// <returns>The formatted attribute.</returns>
68
- public String Attribute ( IAttr attribute ) => ChildFormatter . Attribute ( attribute ) ;
69
-
70
- /// <summary>
71
- /// Formats opening a tag with the given name.
72
- /// </summary>
73
- /// <param name="element">The element to open.</param>
74
- /// <param name="selfClosing">
75
- /// Is the element actually self-closing?
76
- /// </param>
77
- /// <returns>The formatted opening tag.</returns>
78
- public String OpenTag ( IElement element , Boolean selfClosing )
63
+ /// <inheritdoc />
64
+ public virtual String OpenTag ( IElement element , Boolean selfClosing )
79
65
{
80
66
Confirm ( element . Owner . Doctype ) ;
81
67
return ChildFormatter . OpenTag ( element , selfClosing ) ;
82
68
}
83
69
84
- /// <summary>
85
- /// Formats closing a tag with the given name.
86
- /// </summary>
87
- /// <param name="element">The element to close.</param>
88
- /// <param name="selfClosing">
89
- /// Is the element actually self-closing?
90
- /// </param>
91
- /// <returns>The formatted closing tag.</returns>
92
- public String CloseTag ( IElement element , Boolean selfClosing )
70
+ /// <inheritdoc />
71
+ public virtual String CloseTag ( IElement element , Boolean selfClosing )
93
72
{
94
73
Confirm ( element . Owner . Doctype ) ;
95
74
return ChildFormatter . CloseTag ( element , selfClosing ) ;
96
75
}
97
76
98
- /// <summary>
99
- /// Formats the given comment.
100
- /// </summary>
101
- /// <param name="comment">The comment to stringify.</param>
102
- /// <returns>The formatted comment.</returns>
103
- public String Comment ( IComment comment )
77
+ /// <inheritdoc />
78
+ public virtual String Comment ( IComment comment )
104
79
{
105
80
Confirm ( comment . Owner . Doctype ) ;
106
81
return ChildFormatter . Comment ( comment ) ;
107
82
}
108
83
109
- /// <summary>
110
- /// Formats the given doctype using the name, public and system
111
- /// identifiers.
112
- /// </summary>
113
- /// <param name="doctype">The document type to stringify.</param>
114
- /// <returns>The formatted doctype.</returns>
115
- public String Doctype ( IDocumentType doctype )
84
+ /// <inheritdoc />
85
+ public virtual String Doctype ( IDocumentType doctype )
116
86
{
117
87
Confirm ( doctype ) ;
118
88
return ChildFormatter . Doctype ( doctype ) ;
119
89
}
120
90
121
- /// <summary>
122
- /// Formats the given processing instruction using the target and the
123
- /// data.
124
- /// </summary>
125
- /// <param name="processing">
126
- /// The processing instruction to stringify.
127
- /// </param>
128
- /// <returns>The formatted processing instruction.</returns>
129
- public String Processing ( IProcessingInstruction processing )
91
+ /// <inheritdoc />
92
+ public virtual String Processing ( IProcessingInstruction processing )
130
93
{
131
94
Confirm ( processing . Owner . Doctype ) ;
132
95
return ChildFormatter . Processing ( processing ) ;
133
96
}
134
97
135
- /// <summary>
136
- /// Formats the given text.
137
- /// </summary>
138
- /// <param name="text">The text to sanatize.</param>
139
- /// <returns>The formatted text.</returns>
140
- public String Text ( ICharacterData text ) => ChildFormatter . Text ( text ) ;
98
+ /// <inheritdoc />
99
+ public virtual String Text ( ICharacterData text ) => ChildFormatter . Text ( text ) ;
141
100
142
- String IMarkupFormatter . LiteralText ( ICharacterData text ) => ChildFormatter . LiteralText ( text ) ;
101
+ /// <inheritdoc />
102
+ public virtual String LiteralText ( ICharacterData text ) => ChildFormatter . LiteralText ( text ) ;
143
103
144
104
#endregion
145
105
0 commit comments