Exemple #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();
        }
Exemple #2
0
 public decimal Visit(Tobacco tobaccoItem)
 {
     return(tobaccoItem.GetPrice() * 1.5m);
 }