/// <summary> /// Returns a <see cref="System.String"/> that represents this instance. /// </summary> /// <param name="format">The format.</param> /// <param name="formatProvider">The format provider.</param> /// <returns> /// A <see cref="System.String"/> that represents this instance. /// </returns> public string ToString(string format, IFormatProvider formatProvider) { if (format == null) { return(ToString(formatProvider)); } return(string.Format(formatProvider, "{0}°", MyMathf.RadiansToDegrees(radians).ToString(format, CultureInfo.CurrentCulture))); }
/// <summary> /// Returns a <see cref="System.String"/> that represents this instance. /// </summary> /// <param name="formatProvider">The format provider.</param> /// <returns> /// A <see cref="System.String"/> that represents this instance. /// </returns> public string ToString(IFormatProvider formatProvider) { return(string.Format(formatProvider, MyMathf.RadiansToDegrees(radians).ToString("0.##°"))); }
/// <summary> /// Returns a <see cref="System.String"/> that represents this instance. /// </summary> /// <returns> /// A <see cref="System.String"/> that represents this instance. /// </returns> public override string ToString() { return(string.Format(CultureInfo.CurrentCulture, MyMathf.RadiansToDegrees(radians).ToString("0.##°"))); }