KeyMetadata class
Metadata for key-level layout information.
Stores per-key layout and formatting metadata separate from the data itself, enabling 100% round-trip fidelity across format conversions. Supports nested key metadata through the children map.
Constructors
-
KeyMetadata({int? headerLevel, DividerMeta? divider, CalloutMeta? callout, CodeBlockMeta? codeBlock, ListMeta? listMeta, TableMeta? tableMeta, EmphasisMeta? emphasis, XmlMeta? xmlMeta, YamlMeta? yamlMeta, JsonMeta? jsonMeta, WhitespaceMeta? whitespace, Map<
String, KeyMetadata> ? children}) -
Creates a KeyMetadata instance.
const
-
KeyMetadata.fromJson(Map<
String, dynamic> json) -
Creates from JSON map.
factory
Properties
- callout → CalloutMeta?
-
Callout metadata (NOTE, WARNING, TIP, etc.).
final
-
children
→ Map<
String, KeyMetadata> ? -
Nested key metadata for child keys.
final
- codeBlock → CodeBlockMeta?
-
Code block metadata.
final
- divider → DividerMeta?
-
Divider/horizontal rule metadata.
final
- emphasis → EmphasisMeta?
-
Text emphasis metadata (bold, italic, etc.).
final
- hashCode → int
-
The hash code for this object.
no setteroverride
- headerLevel → int?
-
Header level (1-6) for Markdown headers.
final
- jsonMeta → JsonMeta?
-
JSON-specific metadata (indentation, trailing commas).
final
- listMeta → ListMeta?
-
List formatting metadata.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- tableMeta → TableMeta?
-
Table formatting metadata.
final
- whitespace → WhitespaceMeta?
-
Whitespace preservation metadata.
final
- xmlMeta → XmlMeta?
-
XML-specific metadata (attributes, CDATA, comments, namespaces).
final
- yamlMeta → YamlMeta?
-
YAML-specific metadata (anchors, aliases, comments, styles).
final
Methods
-
copyWith(
{int? headerLevel, DividerMeta? divider, CalloutMeta? callout, CodeBlockMeta? codeBlock, ListMeta? listMeta, TableMeta? tableMeta, EmphasisMeta? emphasis, XmlMeta? xmlMeta, YamlMeta? yamlMeta, JsonMeta? jsonMeta, WhitespaceMeta? whitespace, Map< String, KeyMetadata> ? children}) → KeyMetadata - Creates a copy with updated values.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> - Converts to JSON map.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
override