Пример #1
0
		} // toString
	
	
	// HACK snewman 10/17/01: implement toFixed, toExponential, and
	// toPrecision.
	
	// Glue for "toString" with no explicit radix.
	public static string toString(JNumberObject _this)
		{
		return toString(_this, 10);
		} // toString (no explicit radix)
Пример #2
0
	public static string toString(JNumberObject _this, int radix)
		{
		if (radix == 10)
			return _this.ToString();
		else if (radix >= 2 && radix <= 36)
			{
			// HACK snewman 10/17/01: implement non-base-10 radixes, at least
			// for integer values.
			throw new Exception("Number.toString doesn't yet implement radixes other than 10");
			}
		else
			throw new ParameterError("Number.toString radix must be in the range 2...36");
		
		} // toString