package com.henrypump.poc;

import org.bson.Document;
import java.util.Date;

/**
 * Created by patrickjmcd on 2/7/17.
 */
public class WellTest {
    private double testHours;
    private Date testStart;

    private double totalFluidBBL, testOilBBL, testWaterBBL, testGasMCF;
    private double kFactor, oilRatio, waterRatio, gasMCFRatio;


    public WellTest(Date testStart, double testHours, double totalFluidBBL, double testOilBBL, double testWaterBBL, double testGasMCF, double prevDailyTotal) {
        this.testStart = testStart;
        this.testHours = testHours;
        this.totalFluidBBL = totalFluidBBL;
        this.testOilBBL = testOilBBL;
        this.testWaterBBL = testWaterBBL;
        this.testGasMCF = testGasMCF;

        this.oilRatio = this.testOilBBL / this.totalFluidBBL;
        this.waterRatio = this.testWaterBBL / this.totalFluidBBL;
        this.gasMCFRatio = this.testGasMCF / this.totalFluidBBL;

        this.kFactor = 1.0;

        if(prevDailyTotal != -1.0){;
            this.kFactor = this.totalFluidBBL / prevDailyTotal;
        } else {
            System.out.println("No production data in db");
        }
    }

    public double getTestHours() {
        return testHours;
    }

    public Date getTestStart() {
        return testStart;
    }

    public double getTotalFluidBBL() {
        return totalFluidBBL;
    }

    public double getTestOilBBL() {
        return testOilBBL;
    }

    public double getTestWaterBBL() {
        return testWaterBBL;
    }

    public double getTestGasMCF() {
        return testGasMCF;
    }

    public double getkFactor() {
        return kFactor;
    }

    public double getOilRatio() {
        return oilRatio;
    }

    public double getWaterRatio() {
        return waterRatio;
    }

    public double getGasMCFRatio() {
        return gasMCFRatio;
    }

}
