Beispiel #1
0
        public override bool Equals(object obj)
        {
            AbstractEquipmentType aet = obj as AbstractEquipmentType;

            if (OneTimeFee != aet.OneTimeFee)
            {
                return(false);
            }

            if (PremiumFee != aet.PremiumFee)
            {
                return(false);
            }

            if (RegularFee != aet.RegularFee)
            {
                return(false);
            }

            if (LoyaltyPoints != aet.LoyaltyPoints)
            {
                return(false);
            }

            return(true);
        }
Beispiel #2
0
        private void BindEquipmentType()
        {
            switch (this.TypeID)
            {
            case EquipmentTypes.Regular:
                Type = new Regular();
                break;

            case EquipmentTypes.Heavy:
                Type = new Heavy();
                break;

            case EquipmentTypes.Specialized:
                Type = new Specialized();
                break;
            }
        }