Exemplo n.º 1
0
 public void UpdateHistogramByData(double[] passwordsLengths)
 {
     histogramChart.Series.Last().Points.Clear();
     for (int i = 0; i < passwordsLengths.Length; i++)
     {
         histogramChart.Series.Last().Points.AddY(TimeSpanConverter.TotalSeconds(passwordsLengths[i]));
     }
 }
Exemplo n.º 2
0
 public double[] GetPasswordDurations(List <PasswordAction> passwordActions)//исправить long и int
 {
     double[] result = new double[passwordActions.Count()];
     for (int i = 0; i < result.Length; i++)
     {
         result[i] = TimeSpanConverter.TotalSeconds(passwordActions[i].TimeDuration);
     }
     return(result);
 }
Exemplo n.º 3
0
 public double[] GetPasswordsVelocity(List <PasswordAction> passwordActions)
 {
     double[] result = new double[passwordActions.Count()];
     for (int i = 0; i < result.Length; i++)
     {
         result[i] = passwordActions[i].ValidPassword.Length / TimeSpanConverter.TotalSeconds(passwordActions[i].TimeDuration);
     }
     return(result);
 }
Exemplo n.º 4
0
 protected double FormatY(double value)
 {
     return(TimeSpanConverter.TotalSeconds(value));
 }