callUseCase method
Implementation
@override
Future<Either<Exception, dynamic>> callUseCase(
String id, Map<String, dynamic> json) async {
try {
final usecase = getUseCase(id);
final params = _useCaseParamsMapper.fromID(id, json);
return usecase.call(params) as Future<Either<Exception, dynamic>>;
} catch (e) {
return Left(Exception('Error executing use case id: $id, error: $e'));
}
}