Rev 781 | Details | Compare with Previous | Last modification | View Log | RSS feed
| Rev | Author | Line No. | Line |
|---|---|---|---|
| 767 | blopes | 1 | package br.com.sl.domain.dto.robo; |
| 2 | |||
| 3 | import java.math.BigDecimal; |
||
| 781 | blopes | 4 | import java.util.Date; |
| 767 | blopes | 5 | |
| 781 | blopes | 6 | import br.com.ec.core.util.VerificadorUtil; |
| 767 | blopes | 7 | import br.com.kronus.core.PadraoGatilho; |
| 8 | import br.com.sl.domain.model.Candle; |
||
| 779 | blopes | 9 | import br.com.sl.domain.model.tipos.TipoSinal; |
| 767 | blopes | 10 | |
| 11 | public class SinalTradeGatilho3 { |
||
| 12 | |||
| 794 | blopes | 13 | private String idAtivo; |
| 779 | blopes | 14 | private TipoSinal tipoOperacao; |
| 767 | blopes | 15 | private int contratosTotais; |
| 16 | private int contratosEntrada1; |
||
| 17 | private int contratosEntrada2; |
||
| 18 | |||
| 19 | private BigDecimal precoEntrada1; // 50% |
||
| 20 | private BigDecimal precoEntrada2; // 75% |
||
| 21 | |||
| 22 | private BigDecimal alvo1; // 123,6% |
||
| 23 | private BigDecimal alvo2; // 300% (ou depois você ajusta para FVG/FVA) |
||
| 24 | |||
| 25 | private BigDecimal stopMenos100; // nível -100% da fibo |
||
| 26 | // opcional: stopAlternativo baseado em 25% acima/abaixo do fundo/topo relevante |
||
| 27 | private BigDecimal stopAlternativo; |
||
| 28 | |||
| 29 | private PadraoGatilho padrao; |
||
| 30 | private Candle referencia; |
||
| 770 | blopes | 31 | private Candle gatilho1; |
| 767 | blopes | 32 | private Candle gatilho2; |
| 33 | private Candle gatilho3; |
||
| 34 | |||
| 35 | // Getters e setters |
||
| 794 | blopes | 36 | |
| 37 | public String getIdAtivo() { |
||
| 38 | return idAtivo; |
||
| 39 | } |
||
| 40 | public void setIdAtivo(String idAtivo) { |
||
| 41 | this.idAtivo = idAtivo; |
||
| 42 | } |
||
| 767 | blopes | 43 | |
| 779 | blopes | 44 | public TipoSinal getTipoOperacao() { |
| 767 | blopes | 45 | return tipoOperacao; |
| 46 | } |
||
| 47 | |||
| 779 | blopes | 48 | public void setTipoOperacao(TipoSinal tipoOperacao) { |
| 767 | blopes | 49 | this.tipoOperacao = tipoOperacao; |
| 50 | } |
||
| 51 | |||
| 52 | public int getContratosTotais() { |
||
| 53 | return contratosTotais; |
||
| 54 | } |
||
| 55 | |||
| 56 | public void setContratosTotais(int contratosTotais) { |
||
| 57 | this.contratosTotais = contratosTotais; |
||
| 58 | } |
||
| 59 | |||
| 60 | public int getContratosEntrada1() { |
||
| 61 | return contratosEntrada1; |
||
| 62 | } |
||
| 63 | |||
| 64 | public void setContratosEntrada1(int contratosEntrada1) { |
||
| 65 | this.contratosEntrada1 = contratosEntrada1; |
||
| 66 | } |
||
| 67 | |||
| 68 | public int getContratosEntrada2() { |
||
| 69 | return contratosEntrada2; |
||
| 70 | } |
||
| 71 | |||
| 72 | public void setContratosEntrada2(int contratosEntrada2) { |
||
| 73 | this.contratosEntrada2 = contratosEntrada2; |
||
| 74 | } |
||
| 75 | |||
| 76 | public BigDecimal getPrecoEntrada1() { |
||
| 77 | return precoEntrada1; |
||
| 78 | } |
||
| 79 | |||
| 80 | public void setPrecoEntrada1(BigDecimal precoEntrada1) { |
||
| 81 | this.precoEntrada1 = precoEntrada1; |
||
| 82 | } |
||
| 83 | |||
| 84 | public BigDecimal getPrecoEntrada2() { |
||
| 85 | return precoEntrada2; |
||
| 86 | } |
||
| 87 | |||
| 88 | public void setPrecoEntrada2(BigDecimal precoEntrada2) { |
||
| 89 | this.precoEntrada2 = precoEntrada2; |
||
| 90 | } |
||
| 91 | |||
| 92 | public BigDecimal getAlvo1() { |
||
| 93 | return alvo1; |
||
| 94 | } |
||
| 95 | |||
| 96 | public void setAlvo1(BigDecimal alvo1) { |
||
| 97 | this.alvo1 = alvo1; |
||
| 98 | } |
||
| 99 | |||
| 100 | public BigDecimal getAlvo2() { |
||
| 101 | return alvo2; |
||
| 102 | } |
||
| 103 | |||
| 104 | public void setAlvo2(BigDecimal alvo2) { |
||
| 105 | this.alvo2 = alvo2; |
||
| 106 | } |
||
| 107 | |||
| 108 | public BigDecimal getStopMenos100() { |
||
| 109 | return stopMenos100; |
||
| 110 | } |
||
| 111 | |||
| 112 | public void setStopMenos100(BigDecimal stopMenos100) { |
||
| 113 | this.stopMenos100 = stopMenos100; |
||
| 114 | } |
||
| 115 | |||
| 116 | public BigDecimal getStopAlternativo() { |
||
| 117 | return stopAlternativo; |
||
| 118 | } |
||
| 119 | |||
| 120 | public void setStopAlternativo(BigDecimal stopAlternativo) { |
||
| 121 | this.stopAlternativo = stopAlternativo; |
||
| 122 | } |
||
| 123 | |||
| 124 | public PadraoGatilho getPadrao() { |
||
| 125 | return padrao; |
||
| 126 | } |
||
| 127 | |||
| 128 | public void setPadrao(PadraoGatilho padrao) { |
||
| 129 | this.padrao = padrao; |
||
| 130 | } |
||
| 131 | |||
| 132 | public Candle getReferencia() { |
||
| 133 | return referencia; |
||
| 134 | } |
||
| 135 | |||
| 136 | public void setReferencia(Candle referencia) { |
||
| 137 | this.referencia = referencia; |
||
| 138 | } |
||
| 770 | blopes | 139 | |
| 140 | public Candle getGatilho1() { |
||
| 141 | return gatilho1; |
||
| 142 | } |
||
| 143 | public void setGatilho1(Candle gatilho1) { |
||
| 144 | this.gatilho1 = gatilho1; |
||
| 145 | } |
||
| 146 | |||
| 767 | blopes | 147 | public Candle getGatilho2() { |
| 148 | return gatilho2; |
||
| 149 | } |
||
| 150 | |||
| 151 | public void setGatilho2(Candle gatilho2) { |
||
| 152 | this.gatilho2 = gatilho2; |
||
| 153 | } |
||
| 154 | |||
| 155 | public Candle getGatilho3() { |
||
| 156 | return gatilho3; |
||
| 157 | } |
||
| 158 | |||
| 159 | public void setGatilho3(Candle gatilho3) { |
||
| 160 | this.gatilho3 = gatilho3; |
||
| 161 | } |
||
| 162 | |||
| 781 | blopes | 163 | public Date getDataHoraEntrada() { |
| 164 | return VerificadorUtil.naoEstaNulo(getGatilho3())? getGatilho3().getDataHora() : null; |
||
| 165 | } |
||
| 166 | |||
| 767 | blopes | 167 | } |