public static BCD Abs(BCD bcd) { try { BCD ret = bcd.Clone(); ret.SetSign(0); return(ret); } catch (Exception ex) { throw new BCDException("Abs error.", bcd, ex); } }
public static BCD Multiply10(BCD org, int digit) { try { BCD ans = org.Clone(); for (int i = 0; digit > i; i++) { ans.BCDbyteValue.Add(Once.Zero); } ans.MaxLen = ans.BCDbyteValue.Count; return(ans); } catch (Exception ex) { throw new BCDException("Multiply10 error.", org, ex); } }