Exemple #1
0
        public virtual bool IsFasterThan(Db4objects.Db4o.Bench.Delaying.MachineCharacteristics
                                         otherMachine)
        {
            bool result = true;

            for (int i = 0; i < Delays.Count; i++)
            {
                result = result && (times.values[i] <= otherMachine.times.values[i]);
            }
            return(result);
        }
Exemple #2
0
 public virtual void ValidateData()
 {
     if (_machine1.IsFasterThan(_machine2))
     {
         _fasterMachine = _machine1;
         _slowerMachine = _machine2;
         Sharpen.Runtime.Out.WriteLine("> machine1 (" + _machine1.LogFileName() + ") is faster!"
                                       );
     }
     else
     {
         if (_machine2.IsFasterThan(_machine1))
         {
             _fasterMachine = _machine2;
             _slowerMachine = _machine1;
             Sharpen.Runtime.Out.WriteLine("> machine2 (" + _machine2.LogFileName() + ") is faster!"
                                           );
         }
     }
 }
Exemple #3
0
		public virtual void ValidateData()
		{
			if (_machine1.IsFasterThan(_machine2))
			{
				_fasterMachine = _machine1;
				_slowerMachine = _machine2;
				Sharpen.Runtime.Out.WriteLine("> machine1 (" + _machine1.LogFileName() + ") is faster!"
					);
			}
			else
			{
				if (_machine2.IsFasterThan(_machine1))
				{
					_fasterMachine = _machine2;
					_slowerMachine = _machine1;
					Sharpen.Runtime.Out.WriteLine("> machine2 (" + _machine2.LogFileName() + ") is faster!"
						);
				}
			}
		}
Exemple #4
0
 /// <exception cref="NumberFormatException"></exception>
 /// <exception cref="IOException"></exception>
 public DelayCalculation(string logFileName1, string logFileName2)
 {
     _machine1 = new MachineCharacteristics(logFileName1);
     _machine2 = new MachineCharacteristics(logFileName2);
 }
Exemple #5
0
		/// <exception cref="NumberFormatException"></exception>
		/// <exception cref="IOException"></exception>
		public DelayCalculation(string logFileName1, string logFileName2)
		{
			_machine1 = new MachineCharacteristics(logFileName1);
			_machine2 = new MachineCharacteristics(logFileName2);
		}