This repository was archived by the owner on Nov 20, 2018. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +18
-6
lines changed
src/Microsoft.Framework.WebEncoders Expand file tree Collapse file tree 3 files changed +18
-6
lines changed Original file line number Diff line number Diff line change @@ -28,6 +28,7 @@ public unsafe sealed class HtmlEncoder : IHtmlEncoder
28
28
29
29
/// <summary>
30
30
/// Instantiates an encoder using <see cref="UnicodeRanges.BasicLatin"/> as its allow list.
31
+ /// Any character not in the <see cref="UnicodeRanges.BasicLatin"/> range will be escaped.
31
32
/// </summary>
32
33
public HtmlEncoder ( )
33
34
: this ( HtmlUnicodeEncoder . BasicLatin )
@@ -36,15 +37,18 @@ public HtmlEncoder()
36
37
37
38
/// <summary>
38
39
/// Instantiates an encoder specifying which Unicode character ranges are allowed to
39
- /// pass through the encoder unescaped.
40
+ /// pass through the encoder unescaped. Any character not in the set of ranges specified
41
+ /// by <paramref name="allowedRanges"/> will be escaped.
40
42
/// </summary>
41
43
public HtmlEncoder ( params UnicodeRange [ ] allowedRanges )
42
44
: this ( new HtmlUnicodeEncoder ( new CodePointFilter ( allowedRanges ) ) )
43
45
{
44
46
}
45
47
46
48
/// <summary>
47
- /// Instantiates an encoder using a custom code point filter.
49
+ /// Instantiates an encoder using a custom code point filter. Any character not in the
50
+ /// set returned by <paramref name="filter"/>'s <see cref="ICodePointFilter.GetAllowedCodePoints"/>
51
+ /// method will be escaped.
48
52
/// </summary>
49
53
public HtmlEncoder ( ICodePointFilter filter )
50
54
: this ( new HtmlUnicodeEncoder ( CodePointFilter . Wrap ( filter ) ) )
Original file line number Diff line number Diff line change @@ -28,6 +28,7 @@ public sealed class JavaScriptStringEncoder : IJavaScriptStringEncoder
28
28
29
29
/// <summary>
30
30
/// Instantiates an encoder using <see cref="UnicodeRanges.BasicLatin"/> as its allow list.
31
+ /// Any character not in the <see cref="UnicodeRanges.BasicLatin"/> range will be escaped.
31
32
/// </summary>
32
33
public JavaScriptStringEncoder ( )
33
34
: this ( JavaScriptStringUnicodeEncoder . BasicLatin )
@@ -36,15 +37,18 @@ public JavaScriptStringEncoder()
36
37
37
38
/// <summary>
38
39
/// Instantiates an encoder specifying which Unicode character ranges are allowed to
39
- /// pass through the encoder unescaped.
40
+ /// pass through the encoder unescaped. Any character not in the set of ranges specified
41
+ /// by <paramref name="allowedRanges"/> will be escaped.
40
42
/// </summary>
41
43
public JavaScriptStringEncoder ( params UnicodeRange [ ] allowedRanges )
42
44
: this ( new JavaScriptStringUnicodeEncoder ( new CodePointFilter ( allowedRanges ) ) )
43
45
{
44
46
}
45
47
46
48
/// <summary>
47
- /// Instantiates an encoder using a custom code point filter.
49
+ /// Instantiates an encoder using a custom code point filter. Any character not in the
50
+ /// set returned by <paramref name="filter"/>'s <see cref="ICodePointFilter.GetAllowedCodePoints"/>
51
+ /// method will be escaped.
48
52
/// </summary>
49
53
public JavaScriptStringEncoder ( ICodePointFilter filter )
50
54
: this ( new JavaScriptStringUnicodeEncoder ( CodePointFilter . Wrap ( filter ) ) )
Original file line number Diff line number Diff line change @@ -28,6 +28,7 @@ public sealed class UrlEncoder : IUrlEncoder
28
28
29
29
/// <summary>
30
30
/// Instantiates an encoder using <see cref="UnicodeRanges.BasicLatin"/> as its allow list.
31
+ /// Any character not in the <see cref="UnicodeRanges.BasicLatin"/> range will be escaped.
31
32
/// </summary>
32
33
public UrlEncoder ( )
33
34
: this ( UrlUnicodeEncoder . BasicLatin )
@@ -36,15 +37,18 @@ public UrlEncoder()
36
37
37
38
/// <summary>
38
39
/// Instantiates an encoder specifying which Unicode character ranges are allowed to
39
- /// pass through the encoder unescaped.
40
+ /// pass through the encoder unescaped. Any character not in the set of ranges specified
41
+ /// by <paramref name="allowedRanges"/> will be escaped.
40
42
/// </summary>
41
43
public UrlEncoder ( params UnicodeRange [ ] allowedRanges )
42
44
: this ( new UrlUnicodeEncoder ( new CodePointFilter ( allowedRanges ) ) )
43
45
{
44
46
}
45
47
46
48
/// <summary>
47
- /// Instantiates an encoder using a custom code point filter.
49
+ /// Instantiates an encoder using a custom code point filter. Any character not in the
50
+ /// set returned by <paramref name="filter"/>'s <see cref="ICodePointFilter.GetAllowedCodePoints"/>
51
+ /// method will be escaped.
48
52
/// </summary>
49
53
public UrlEncoder ( ICodePointFilter filter )
50
54
: this ( new UrlUnicodeEncoder ( CodePointFilter . Wrap ( filter ) ) )
You can’t perform that action at this time.
0 commit comments