Пример #1
0
        public async Task InitializeAsync()
        {
            var filePath = Path.Combine(AppContext.BaseDirectory, DataConstants.DAT_FILE_PATH);

            await using var stream = _readerService.Read(filePath);

            DatInfo = new DatInfo(stream, 1);
            var records = DatInfo.Records;

            var ipIntervalsInformations = new IUserIp[records];
            var coordinateInformations  = new IUserLocation[records];

            for (var index = 0; index < records; index++)
            {
                ipIntervalsInformations[index] = new UserIp(stream, index + 1);
            }

            for (var index = 0; index < records; index++)
            {
                coordinateInformations[index] = new UserLocation(stream, index + 1);
            }

            UserIps       = new ConcurrentQueue <IUserIp>(ipIntervalsInformations);
            UserLocations = new ConcurrentQueue <IUserLocation>(coordinateInformations);
        }
Пример #2
0
 public StripeController(IUserIp _userIpService)
 {
     this.userIpService = _userIpService;
 }
Пример #3
0
 public UserIpController(IUserIp userIpService)
 {
     this.userIpService = userIpService;
 }