getSuperBlock method
Get the blocks that pertain to the superblock index
Implementation
Future<Map<String, dynamic>> getSuperBlock() async {
try {
var response = await sendMessage(formatRequest(method: 'getSuperBlock'))
.then((Map<String, dynamic> data) {
if (data.containsKey('result')) {
return data['result'];
} else if (data.containsKey('error')) {
throw NodeException.fromJson(data['error']);
}
});
return response;
} on NodeException catch (e) {
throw NodeException(
code: e.code, message: '{"getSuperBlock": "${e.message}"}');
}
}