Interface IDepartureMapper
Converts departure API DTOs into strongly typed departure objects.
public interface IDepartureMapper
Methods
Map(DepartureContract)
Maps a single API departure response object to a domain Departure instance.
Departure Map(DepartureResponseContract.DepartureContract source)
Parameters
sourceDepartureResponseContract.DepartureContractThe API departure response object to convert.
Returns
Map(IEnumerable<DepartureContract>)
Maps a collection of DotVgn.Common.Contracts.DepartureResponseContract to a read-only list of domain Departure instances.
IReadOnlyList<Departure> Map(IEnumerable<DepartureResponseContract.DepartureContract> source)
Parameters
sourceIEnumerable<DepartureResponseContract.DepartureContract>The collection of API departure response objects to convert. Cannot be null.
Returns
- IReadOnlyList<Departure>
A read-only list of Departure objects representing the mapped departures. The list will be empty if the source collection contains no items.