rename method
A WorkspaceEdit renaming the symbol at position to newName, or null.
Implementation
Future<WorkspaceEdit?> rename(
String uri,
Position position,
String newName,
) async {
final r = await sendRequest('textDocument/rename', {
'textDocument': {'uri': uri},
'position': position.toJson(),
'newName': newName,
});
return r is Map ? WorkspaceEdit.fromJson(r.cast<String, Object?>()) : null;
}