package common.context;

import org.springframework.context.ApplicationContext;
import org.springframework.context.ApplicationContextAware;
import org.springframework.stereotype.Service;

/**
 * Created by nolan on 08/11/2016.
 * description:
 */
@Service
public class AppUtils
        implements ApplicationContextAware {
    private static ApplicationContext applicationContext = null;

    public static ApplicationContext getApplicationContext() {
        return AppUtils.applicationContext;
    }

    @Override
    public void setApplicationContext(ApplicationContext applicationContext) {
        AppUtils.applicationContext = applicationContext;
    }
}
