示例#1
0
        public VisitorForm()
        {
            InitializeComponent();
            _liqour         = new Liquor();
            lbLiquor.Text  += _liqour.GetPrice().ToString();
            _tobacco        = new Tobacco();
            lbTobacco.Text += _tobacco.GetPrice().ToString();
            _hamburger      = new Hamburger();
            lbBurger.Text  += _hamburger.GetPrice().ToString();

            _visitor = new DutchVisitor();
            SwitchDutch();
        }
示例#2
0
 public decimal Visit(Liquor liqourItem)
 {
     return(liqourItem.GetPrice() * 1.4m);
 }