Ejemplo n.º 1
0
 public virtual void Reset(int randomSeed)
 {
     Now       = StartDate;
     Random    = new SystemRandom(randomSeed);
     ScheduleQ = new EventQueue(InitialMaxEvents);
     Queue     = new Queue <Event>();
 }
Ejemplo n.º 2
0
 public Environment(DateTime initialDateTime, int randomSeed, TimeSpan? defaultStep = null) {
   DefaultTimeStepSeconds = (defaultStep ?? TimeSpan.FromSeconds(1)).Duration().TotalSeconds;
   StartDate = initialDateTime;
   Now = initialDateTime;
   Random = new SystemRandom(randomSeed);
   ScheduleQ = new EventQueue(InitialMaxEvents);
   Queue = new Queue<Event>();
   Logger = Console.Out;
 }
Ejemplo n.º 3
0
 public Environment(DateTime initialDateTime, TimeSpan?defaultStep = null)
 {
     DefaultTimeStepSeconds = (defaultStep ?? TimeSpan.FromSeconds(1)).Duration().TotalSeconds;
     StartDate = initialDateTime;
     Now       = initialDateTime;
     Random    = new SystemRandom();
     ScheduleQ = new EventQueue(InitialMaxEvents);
     Queue     = new Queue <Event>();
     Logger    = Console.Out;
 }
Ejemplo n.º 4
0
 public Environment(DateTime initialDateTime, int randomSeed, TimeSpan?defaultStep = null)
     : base(initialDateTime, randomSeed, defaultStep)
 {
     Random = new SystemRandom(randomSeed);
 }
Ejemplo n.º 5
0
 public Environment(DateTime initialDateTime, TimeSpan?defaultStep = null)
     : base(initialDateTime, defaultStep)
 {
     Random = new SystemRandom();
 }
Ejemplo n.º 6
0
 public Environment(int randomSeed, TimeSpan?defaultStep = null)
     : base(randomSeed, defaultStep)
 {
     Random = new SystemRandom(randomSeed);
 }
Ejemplo n.º 7
0
 public Environment(TimeSpan?defaultStep)
     : base(defaultStep)
 {
     Random = new SystemRandom();
 }
Ejemplo n.º 8
0
 public Environment()
     : base()
 {
     Random = new SystemRandom();
 }
Ejemplo n.º 9
0
 public virtual void Reset(int randomSeed) {
   ProcessedEvents = 0;
   Now = StartDate;
   Random = new SystemRandom(randomSeed);
   ScheduleQ = new EventQueue(InitialMaxEvents);
   Queue = new Queue<Event>();
 }