public NotaFiscal Gera(Fatura fatura) { double valor = fatura.ValorMensal; NotaFiscal nf = new NotaFiscal(valor, ImpostoSimplesSobreO(valor)); email.EnviaEmail(nf); dao.Persiste(nf); return(nf); }
public NotaFiscal Gera(Fatura fatura) { double valor = fatura.ValorMensal; NotaFiscal nf = new NotaFiscal(valor, ImpostoSimplesSobreO(valor)); // - Problem - this class depends on email and dao email.EnviaEmail(nf); dao.Persiste(nf); return(nf); }