Exemplo n.º 1
0
        public FrenchTicketBuilder()
        {
            lineTicketOperation = new PriceCalculatorOperation();
            TicketOperationComposite globalTicketOperationComposite = new TicketOperationComposite();

            globalTicketOperationComposite.Add(new PriceCalculatorOperation());
            globalTicketOperationComposite.Add(new TaxPrinterOperation());
            globalTicketOperation = globalTicketOperationComposite;
        }
Exemplo n.º 2
0
        public SpanishTicketBuilder()
        {
            //Configuro las operacion que va a tener: global y de linea
            TicketOperationComposite lineTicketOperationComposite = new TicketOperationComposite();

            lineTicketOperationComposite.Add(new PriceCalculatorOperation());
            lineTicketOperationComposite.Add(new ClientPrinterOperation());
            lineTicketOperationComposite.Add(new TaxPrinterOperation());
            lineTicketOperation = lineTicketOperationComposite;
            TicketOperationComposite globalTicketOperationComposite = new TicketOperationComposite();

            lineTicketOperationComposite.Add(new PriceCalculatorOperation());
            lineTicketOperationComposite.Add(new ClientPrinterOperation());
            lineTicketOperationComposite.Add(new TaxPrinterOperation());
            globalTicketOperation = globalTicketOperationComposite;
        }