// a method that create a guest public GuestDecorator CreateGuest(string name, string passportNumber, int age) { GuestDecorator guest = new GuestDecorator(passportNumber, age); guest.Name = name; return(guest); }
// method that decorates a client as a guest public GuestDecorator CreateClientGuest(Client client, string passportNumber, int age) { GuestDecorator guest = new GuestDecorator(passportNumber, age); guest.SetComponent(client); return(guest); }