private toString ( Object thisob, Object radix ) : String | ||
thisob | Object | |
radix | Object | |
return | String |
public static String toString(Object thisob, Object radix){
int rdx = 10;
if (radix is IConvertible){
double rd = ((IConvertible)radix).ToDouble(CultureInfo.InvariantCulture);
int ri = (int)rd;
if (rd == (double)ri)
rdx = ri;
}
if (rdx < 2 || rdx > 36)
rdx = 10;
return Convert.ToString(NumberPrototype.valueOf(thisob), rdx);
}
internal override object GetDefaultValue(Type hint, bool avoid_toString) { if (hint == typeof(string)) { return(NumberPrototype.toString(this, 10)); } else { return(value); } }