private static string doubleArrayToString(double[] array, int num) { StringBuilder stringBuilder = new StringBuilder().append(array.Length); int num2 = array.Length; for (int i = 0; i < num2; i++) { double num3 = array[i]; if (num == 3) { stringBuilder.append(' ').append(DataUtil.formatDouble(num3, 10, 5)); } else if (num == 1) { DoubleConverter doubleConverter = new DoubleConverter(); long num4 = DoubleConverter.ToLong(num3, ref doubleConverter); stringBuilder.append(" 0x").append(Long.toHexString(num4)); } else if (num == 2) { stringBuilder.append(' ').append(Utilities.doubleToScientificString(num3, 8)); } } return(stringBuilder.toString()); }
private static string floatArrayToString(float[] array, int num) { StringBuilder stringBuilder = new StringBuilder().append(array.Length); int num2 = array.Length; for (int i = 0; i < num2; i++) { float num3 = array[i]; if (num == 3) { stringBuilder.append(' ').append(DataUtil.formatDouble((double)num3, 10, 5)); } else if (num == 1) { FloatConverter floatConverter = new FloatConverter(); int num4 = FloatConverter.ToInt(num3, ref floatConverter); stringBuilder.append(" 0x").append(Integer.toHexString(num4)); } else if (num == 2) { stringBuilder.append(' ').append(Utilities.doubleToScientificString((double)num3, 8)); } } return(stringBuilder.toString()); }