sharee.bike-App/SharedBusinessLogic/Services/CopriApi/StationsAndBikesContainer.cs

40 lines
1.3 KiB
C#
Raw Normal View History

2024-04-09 12:53:23 +02:00
using ShareeBike.Model.Bikes;
using ShareeBike.Model.Stations;
2021-05-13 20:03:07 +02:00
2024-04-09 12:53:23 +02:00
namespace ShareeBike.Model.Services.CopriApi
2021-05-13 20:03:07 +02:00
{
2023-05-09 08:47:52 +02:00
/// <summary>
/// Holds stations and bikes.
/// </summary>
2022-09-06 16:08:19 +02:00
public class StationsAndBikesContainer
{
2023-05-09 08:47:52 +02:00
/// <summary>
/// Holds station and bikes.
/// </summary>
/// <param name="stations">Stations information which contains some information about bikes available at each station (bike count, ...).</param>
/// <param name="bikesOccupied"></param>
public StationsAndBikesContainer(StationDictionary stations, BikeCollection bikesOccupied)
2022-09-06 16:08:19 +02:00
{
StationsAll = stations;
2023-05-09 08:47:52 +02:00
BikesOccupied = bikesOccupied;
2022-09-06 16:08:19 +02:00
}
2023-05-09 08:47:52 +02:00
/// <summary>
/// Holds all stations.
/// </summary>
/// <remarks>
/// Since copri version writing <see cref="StationType"/> (>= 4.1.23.03) stations contain bikes available information.
/// Prior to this copri version bikes available were part of <see cref="BikesOccupied"/>
/// </remarks>
2022-09-06 16:08:19 +02:00
public StationDictionary StationsAll { get; }
2021-05-13 20:03:07 +02:00
2023-05-09 08:47:52 +02:00
/// <summary>
/// Holds bikes occupied (i.e. bike reserved or booked).
/// </summary>
/// <remarks>
/// Up to copri version writing <see cref="StationType"/> (>= 4.1.23.03) bike available were contained beside bikes occupied.
/// </remarks>
public BikeCollection BikesOccupied { get; }
2022-09-06 16:08:19 +02:00
}
2021-05-13 20:03:07 +02:00
}