Files
gridpilot.gg/adapters/racing/services/InMemoryRankingService.ts
2025-12-16 13:13:03 +01:00

21 lines
774 B
TypeScript

import type { IRankingService, DriverRanking } from '@core/racing/domain/services/IRankingService';
import type { Logger } from '@core/shared/application';
export class InMemoryRankingService implements IRankingService {
constructor(private readonly logger: Logger) {
this.logger.info('InMemoryRankingService initialized.');
}
getAllDriverRankings(): DriverRanking[] {
this.logger.debug('[InMemoryRankingService] Getting all driver rankings.');
// Mock data for demonstration purposes
const mockRankings: DriverRanking[] = [
{ driverId: 'driver-1', rating: 2500, overallRank: 1 },
{ driverId: 'driver-2', rating: 2400, overallRank: 2 },
{ driverId: 'driver-3', rating: 2300, overallRank: 3 },
];
return mockRankings;
}
}