All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.github.longhaoteng.sdk.common.BaseEntity Maven / Gradle / Ivy

The newest version!
package com.github.longhaoteng.sdk.common;

import org.springframework.context.ApplicationContext;

/**
 * BaseEntity
 *
 * @author mr.long
 */
public abstract class BaseEntity {

    private ApplicationContext applicationContext;

    public BaseEntity() {
        applicationContext = ApplicationContextKeeper.getApplicationContext();
    }

    protected  T getBean(Class beanClass) {
        return applicationContext.getBean(beanClass);
    }

    protected  T getBean(String name, Class beanClass) {
        return applicationContext.getBean(name, beanClass);
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy