//package Knowledgebase;
//
//import org.json.JSONArray;
//import org.kie.api.KieServices;
//import org.kie.api.KieServices.Factory;
//import org.kie.api.runtime.KieContainer;
//import org.kie.api.runtime.KieSession;
//import org.kie.api.runtime.rule.FactHandle;
//
//import java.util.ArrayList;
//import java.util.HashMap;
//import java.util.Map;
//
//public class DroolsTest {
//     private Map<String, Double> currMap= new HashMap<>();
//
//    public static final void main(String[] args) {
//        try {
//            KieServices ks = KieServices.Factory.get();
//            KieContainer kContainer = ks.getKieClasspathContainer();
////Get the session named kseesion-rule that we defined in kmodule.xml above.
////Also by default the session returned is always stateful.
//            KieSession kSession = kContainer.newKieSession("ksession-rule");
//
//            currMap.put("asd",12.2);
//            setCurrMap("soilMoisture",10.1);
//            currMap.put("soilConductivity",0.14);
//            setCurrMap set= new SetCurrMap();
//            se
//
//
//            FactHandle fact1;
//
//            fact1 = kSession.insert(currMap);
//            System.out.println(fact1);
//            kSession.fireAllRules();
//
////            System.out.println("The discount for the jewellery product "
////                    + sensorReadings.getSensorTag() + " is " + sensorReadings.getValue());
//
//        } catch (Throwable t) {
//            t.printStackTrace();
//        }
//    }
//    public Map<String, Double> getCurrMap() {
//        return currMap;
//    }
//
//    public void setCurrMap(Map<String, Double> currMap) {
//        this.currMap = currMap;
//    }
//
//}
