Beispiel #1
0
 public ITC(ItcType itctype, double amt, double pct, double rdc)
 {
     Type = (itctype);
     if (Type == ItcType.None)
     {
         clearValues();
     }
     else
     {
         Percentage = (pct);
         Amount     = (amt);
         Reduction  = (rdc);
     }
 }
Beispiel #2
0
        private static char         translateTypeToShortName(ItcType type)
        {
            int i = 0;

            while (codes[i].code != '\0')
            {
                if (codes[i].type == type)
                {
                    return(codes[i].code);
                }
                else
                {
                    ++i;
                }
            }
            return('\0');
        }
Beispiel #3
0
        public double GetDefaultITCPct(PropertyTypeEnum propType, DateTime pisDate, DeprMethodTypeEnum deprMethod, int deprPct, YrsMosDate estLife, ItcType itcType)
        {
            ErrorCode   errorCode;
            double      percentage = 0.0;
            IbpRuleBase rb         = new bpRuleBase();

            rb.GetDefaultITCPercent((short)propType, (pisDate), (short)deprMethod, (short)(estLife.Years * 100 + estLife.Months), (short)itcType, ref percentage, out errorCode);

            if (errorCode == (short)RuleResult.Valid)
            {
                return(percentage);
            }
            return(0.0);
        }
Beispiel #4
0
        public RuleResult IsValid(PropertyTypeEnum propType, DateTime pisDate, DeprMethodTypeEnum deprMethod, int deprPct, YrsMosDate estLife, ItcType itcType)
        {
            ErrorCode   errorCode;
            IbpRuleBase rb = new bpRuleBase();

            rb.ValidateITC((short)propType, pisDate, (short)deprMethod,
                           (short)(estLife.Years * 100 + estLife.Months), (short)itcType, out errorCode);

            return((RuleResult)errorCode);
        }