TextResourceContent.toMCP constructor
Implementation
factory TextResourceContent.toMCP(Map<String, Object?> map) {
return TextResourceContent(
text: map['text'] as String,
data: map['data'] as String,
mimeType: map['mimeType'] as String,
annotations: map['annotations'] != null
? Annotations.toMCP(map['annotations'] as Map<String, Object?>)
: null,
$meta: map['_meta'] != null
? MetaObject.toMCP(map['_meta'] as Map<String, Object?>)
: null,
);
}