HtmlEscape class Null safety
Converter which escapes characters with special meaning in HTML.
The converter finds characters that are significant in HTML source and replaces them with corresponding HTML entities.
The characters that need escaping in HTML are:
&(ampersand) always need to be escaped.
<(less than) and '>' (greater than) when inside an element.
"(quote) when inside a double-quoted attribute value.
'(apostrophe) when inside a single-quoted attribute value. Apostrophe is escaped as
'since not all browsers understand
/(slash) is recommended to be escaped because it may be used to terminate an element in some HTML dialects.
> (greater than) isn't necessary, but the result is often
found to be easier to read if greater-than is also escaped whenever
- HtmlEscape([HtmlEscapeMode mode = HtmlEscapeMode.unknown])
Create converter that escapes HTML characters. [...]
- hashCode → int
The hash code for this object. [...]
- mode → HtmlEscapeMode
The HtmlEscapeMode used by the converter.
- runtimeType → Type
A representation of the runtime type of the object.
Stream< String>stream) → Stream< String>
Transforms the provided
RS, RT>( ) → Converter< RS, RT>
Converter<RS, RT>view of this stream transformer. [...]inherited
String text) → String
inputand returns the result of the conversion.override
TT>( Converter< String, TT>other) → Converter< String, TT>
Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
Sink< String>sink) → StringConversionSink
Starts a chunked conversion. [...]
) → String
A string representation of this object. [...]
Object other) → bool
The equality operator. [...]