C# 클래스 TrainNotifier.Service.LiveTrainRepository

상속: DbRepository, IDisposable
파일 보기 프로젝트 열기: blueghostuk/trainnotifier-server

공개 메소드들

메소드 설명
AddActivation ( TrainActivation activation ) : void
AddCancellation ( CancelledTrainMovementStep cm ) : bool
AddMovement ( TrainMovementStep tms ) : bool
BatchInsertTrainData ( IEnumerable trainData, bool onFailAddToQueue = true ) : void
Dispose ( ) : void
GetMatchingSchedule ( TrainActivation activation ) : MatchSchedule
PreLoadActivations ( ) : void

Pre-loads trains activated or in progress set to depart from 12 hours ago into the future

StartTimer ( ) : void
UpdateMovement ( System.Guid trainId, TDElement td, IEnumerable tiplocIds, TrainMovementEventType eventType, System.DateTime actualTime, LiveTrainStopSource source = LiveTrainStopSource.TD ) : bool

Update a train movement

UpdateTrainState ( System.Guid trainId, TrainState state ) : void

비공개 메소드들

메소드 설명
AddChangeOfOrigin ( TrainChangeOfOrigin tOrigin ) : bool
AddFirstArrivalMovement ( System.Guid trainId, System.DateTime departureTime, ScheduleStop scheduleStop ) : void
AddReinstatement ( TrainReinstatement tr ) : bool
GetDatePartSql ( System.DateTime date ) : string
GetNextStop ( string trainId, TrainMovementEventType eventType, string stanox, byte latestStopNumber ) : ScheduleStop
ProcessQueue ( object ignored ) : void
SetLiveTrainSchedule ( TrainActivation activation, IEnumerable tiplocs ) : void
TrainExists ( string trainId, Activation &tm ) : bool
UpdateLiveTrainOrigin ( System.Guid trainId, short tiplocId ) : void

메소드 상세

AddActivation() 공개 메소드

public AddActivation ( TrainActivation activation ) : void
activation TrainNotifier.Common.Model.TrainActivation
리턴 void

AddCancellation() 공개 메소드

public AddCancellation ( CancelledTrainMovementStep cm ) : bool
cm TrainNotifier.Common.Model.CancelledTrainMovementStep
리턴 bool

AddMovement() 공개 메소드

public AddMovement ( TrainMovementStep tms ) : bool
tms TrainNotifier.Common.Model.TrainMovementStep
리턴 bool

BatchInsertTrainData() 공개 메소드

public BatchInsertTrainData ( IEnumerable trainData, bool onFailAddToQueue = true ) : void
trainData IEnumerable
onFailAddToQueue bool
리턴 void

Dispose() 공개 메소드

public Dispose ( ) : void
리턴 void

GetMatchingSchedule() 공개 메소드

public GetMatchingSchedule ( TrainActivation activation ) : MatchSchedule
activation TrainNotifier.Common.Model.TrainActivation
리턴 MatchSchedule

PreLoadActivations() 공개 메소드

Pre-loads trains activated or in progress set to depart from 12 hours ago into the future
public PreLoadActivations ( ) : void
리턴 void

StartTimer() 공개 메소드

public StartTimer ( ) : void
리턴 void

UpdateMovement() 공개 메소드

Update a train movement
public UpdateMovement ( System.Guid trainId, TDElement td, IEnumerable tiplocIds, TrainMovementEventType eventType, System.DateTime actualTime, LiveTrainStopSource source = LiveTrainStopSource.TD ) : bool
trainId System.Guid id of live train
td TDElement
tiplocIds IEnumerable reporting tiploc(s)
eventType TrainMovementEventType arrival or departure to update
actualTime System.DateTime actual time to set
source LiveTrainStopSource source of data
리턴 bool

UpdateTrainState() 공개 메소드

public UpdateTrainState ( System.Guid trainId, TrainState state ) : void
trainId System.Guid
state TrainState
리턴 void