/**
 * 环境工厂类
 */
const ContextAdditionalTax = require("./additionalTax/contextAdditionalTax");
const ContextValueAddedTax = require("./valueAddedTax/contextValueAddedTax");

class ContextFactory {

  constructor() {
    // this.context = context;
  }

  getInstance(context) {
    let bean = null;
    switch (context) {
      case "additionalTax":
        bean = new ContextAdditionalTax();
        break;
      case "valueAddedTax":
        bean = new ContextValueAddedTax();
        break;
      default:
        console.log("算法环境初始化失败");
        bean = null
    }
    return bean;
  }

}

module.exports=ContextFactory;