Exemplo n.º 1
0
 internal Request(Ranking ranking, DateTimeOffset creationTime, Quarantine quarantine)
 {
     Ranking      = ranking;
     Status       = RequestStatus.LostDueToQuarantine;
     CreatedAt    = creationTime;
     Quarantine   = quarantine;
     QuarantineId = quarantine.QuarantineId;
 }
Exemplo n.º 2
0
 internal RequestGroup(Ranking ranking, DateTimeOffset creationTime, List <Request> requests, Quarantine quarantine)
 {
     requests.ForEach(r => r.RequestGroup = this);
     Ranking      = ranking;
     Status       = RequestStatus.LostDueToQuarantine;
     CreatedAt    = creationTime;
     Quarantine   = quarantine;
     QuarantineId = quarantine.QuarantineId;
 }
Exemplo n.º 3
0
        private RequestGroup CreateQuarantinedRequestGroup(Ranking ranking, DateTimeOffset creationTime, Quarantine quarantine)
        {
            var requestGroup = new RequestGroup(ranking, creationTime, Orders.Select(o => o.CreateQuarantinedRequest(ranking, creationTime, quarantine)).ToList(), quarantine);

            RequestGroups.Add(requestGroup);
            return(requestGroup);
        }
Exemplo n.º 4
0
        internal Request CreateQuarantinedRequest(Ranking ranking, DateTimeOffset creationTime, Quarantine quarantine)
        {
            var request = new Request(ranking, creationTime, quarantine);

            Requests.Add(request);
            return(request);
        }