copyWith method
Implementation
Stanza copyWith({
String? id,
Object? from = _stanzaNotDefined,
String? to,
String? type,
List<XMLNode>? children,
String? xmlns,
}) {
return Stanza(
tag: tag,
to: to ?? this.to,
from: from != _stanzaNotDefined ? from as String? : this.from,
id: id ?? this.id,
type: type ?? this.type,
children: children ?? this.children,
attributes: {
...attributes.cast<String, String>(),
},
xmlns: xmlns ?? this.xmlns,
);
}