// /** // * @name Singleton // * @desc 싱글톤 패턴 적용을 위한 상속자 // */ // // export default class Singleton { // [key:string]:any; // public static instance:any; // // public static getInstance(){ // // if(this.instance) { // return this.instance; // } // // if(this.name === "ApplicationContext") // { // this.instance = new this(); // return this.instance; // } // // let applicationContext = require("../context/ApplicationContext").default; // // if(applicationContext) // { // // // let getFromBean = applicationContext.instance.getBean(this.name, {SCOPE:"singleton"}); // // if(getFromBean) // { // this.instance = getFromBean; // } // else // { // this.instance = new this(); // } // } // // // // let getFromBean = applicationContext.getBean(className, {SCOPE:"singleton"}); // // // // if(getFromBean) // // { // // this.instance = getFromBean; // // } // // else // // { // // this.instance = _instance; // // } // return this.instance; // } // }