예제 #1
0
 public EmisorDeEmails(string mensaje, EProducto producto, string email) : base(mensaje, producto)
 {
     this.email    = email;
     this.enviado  = false;
     this.producto = producto;
     this.mensaje  = mensaje;
 }
예제 #2
0
        private double ObtenerPrecio(EProducto tipoProducto)
        {
            double acumulador = 0;

            foreach (Producto item in this.productos)
            {
                switch (tipoProducto)
                {
                case EProducto.PrecioDeTablets:
                    if (item is Tablet)
                    {
                        acumulador += (double)(Tablet)item;
                    }
                    break;

                case EProducto.PrecioDeCelulares:
                    if (item is Celular)
                    {
                        acumulador += (double)(Celular)item;
                    }
                    break;

                case EProducto.PrecioTotal:
                    if (item is Tablet)
                    {
                        acumulador += (double)(Tablet)item;
                    }
                    if (item is Celular)
                    {
                        acumulador += (Celular)item;
                    }
                    break;
                }
            }
            return(acumulador);
        }
예제 #3
0
 /// <summary>
 /// llama al constructor base y pone al numero cargado en false x defecto
 /// </summary>
 /// <param name="mensaje"></param>
 /// <param name="producto"></param>
 public EmisorDeWhatsapp(string mensaje, EProducto producto) : base(mensaje, producto)
 {
     this.numeroCargado = false;
 }
예제 #4
0
 protected Emisor(string mensaje, EProducto producto)
 {
     this.mensaje  = mensaje;
     this.producto = producto;
 }
예제 #5
0
 public EmisorDeWhatsapp(string mensaje, EProducto producto) : base(mensaje, producto)
 {
 }
예제 #6
0
 public EmisorDeWhatsapp(string mensaje, EProducto producto) : base(mensaje, producto)
 {
     this.producto = producto;
     this.mensaje  = mensaje;
 }