Interface IStationMapper
Converts station API DTOs into strongly typed station objects.
public interface IStationMapper
Methods
Map(StationContract)
Maps a single API station response object to a domain Station instance.
Station Map(StationResponseContract.StationContract source)
Parameters
sourceStationResponseContract.StationContractThe API station response object to convert.
Returns
Map(IEnumerable<StationContract>)
Maps a collection of DotVgn.Common.Contracts.StationResponseContract to a read-only list of domain Station instances.
IReadOnlyList<Station> Map(IEnumerable<StationResponseContract.StationContract> source)
Parameters
sourceIEnumerable<StationResponseContract.StationContract>The collection of API stations response objects to convert. Cannot be null.
Returns
- IReadOnlyList<Station>
A read-only list of Station objects representing the mapped stations. The list will be empty if the source collection contains no items.