Subversion Repositories Integrator Subversion

Rev

Blame | Last modification | View Log | Download | RSS feed

package br.com.robo.model;

import java.time.LocalDateTime;
import java.util.ArrayList;
import java.util.List;

public class Candle {

    private LocalDateTime time;
    private Double open;
    private Double high;
    private Double low;
    private Double close;
    private Double volume;
   
    private Integer tipoTemporizador;

    public Candle(LocalDateTime time, Double open, Double high, Double low, Double close, Double volume) {
        this.time = time;
        this.open = open;
        this.high = high;
        this.low = low;
        this.close = close;
        this.volume = volume;
    }
   
    public Candle(LocalDateTime time, Double open, Double high, Double low, Double close, Integer tipoTemporizador) {
        this.time = time;
        this.open = open;
        this.high = high;
        this.low = low;
        this.close = close;
        this.tipoTemporizador = tipoTemporizador;
    }

    public Candle(LocalDateTime time, int abertura, int topo, int fundo, int fechamento, int tipoTemporizador) {
        this.time = time;
        this.open = new Double(abertura);
        this.high = new Double(topo);
        this.low = new Double(fundo);
        this.close = new Double(fechamento);
        this.tipoTemporizador = new Integer(tipoTemporizador);
    }

        public Candle(LocalDateTime time, double abertura, double topo, double fundo, double fechamento, int tipoTemporizador) {
                this.time = time;
        this.open = new Double(abertura);
        this.high = new Double(topo);
        this.low = new Double(fundo);
        this.close = new Double(fechamento);
        this.tipoTemporizador = new Integer(tipoTemporizador);
        }

        public LocalDateTime getTime() {
        return time;
    }

    public Double getOpen() {
        return open;
    }

    public Double getHigh() {
        return high;
    }

    public Double getLow() {
        return low;
    }

    public Double getClose() {
        return close;
    }

    public Double getVolume() {
        return volume;
    }
   
    public Integer getTipoTemporizador() {
                return tipoTemporizador;
        }

    @Override
    public String toString() {
        return "Candle{" +
                "time=" + time +
                ", open=" + open +
                ", high=" + high +
                ", low=" + low +
                ", close=" + close +
                ", volume=" + volume +
                '}';
    }
   
}