XmlDeclaration class
The XML declaration.
All valid XML documents should begin with an XML declaration.
- Inheritance
-
- Object
- XmlNode
- XmlNodeWithAttributes
- XmlDeclaration
- Annotations
-
- @immutable
Constructors
- XmlDeclaration({required String version, String? encoding, bool? standalone})
-
The XML declaration.
const
Properties
- encoding → String?
-
The encoding character set used by this document.
final
- hashCode → int
-
The hash code for this object.
no setteroverride
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- standalone → bool?
-
Should be
true
if this document only contains internal DTD, andfalse
if this document contains external DTD.final - version → String
-
The version of the XML standard this document conforms to.
final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toFormattedString(
{int nestingLevel = 0, String indent = '\t', bool doubleQuotes = true}) → String -
Returns this node as a formatted string.
inherited
-
toString(
{bool doubleQuotes = true}) → String -
A string representation of this object.
override
Operators
-
operator ==(
Object o) → bool -
The equality operator.
override
Static Methods
-
from(
String string, {bool trimWhitespace = true}) → XmlDeclaration? -
Returns the first XML declaration found in
string
.string
must not benull
.override -
parseString(
String string, {bool trimWhitespace = true, int start = 0, int? stop}) → List< XmlDeclaration> ? -
Returns a list of every XML declaration found in
string
.string
must not benull
.override