import 'package:dartz/dartz.dart';
import '../../repositories/model_repository.dart';
import '../../../data/models/model/model_dto.dart';
import '../../../core/errors/failures.dart';
import '../base_usecase.dart';

/// 모델 상세 조회 UseCase
class GetModelDetailUseCase extends UseCase<ModelDto, int> {
  final ModelRepository _modelRepository;

  GetModelDetailUseCase(this._modelRepository);

  @override
  Future<Either<Failure, ModelDto>> call(int id) async {
    return await _modelRepository.getModelDetail(id);
  }
}