hjg
2024-07-09 4fd62ace17390b0b9cc37c55e88582134ec18c28
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
package com.mandi.common;
 
 
import org.springframework.beans.BeansException;
import org.springframework.context.ApplicationContext;
import org.springframework.context.ApplicationContextAware;
import org.springframework.stereotype.Service;
 
/** 
 * @author mengly 
 * @version 创建时间:2016年3月3日 下午12:32:14 
 * 类说明 
 */
@Service
public class SpringContext implements ApplicationContextAware {
    private static ApplicationContext ctx=null;
    public static ApplicationContext getAppContext()
    {
        return SpringContext.ctx;
    }
    @Override
    public void setApplicationContext(ApplicationContext arg0)
            throws BeansException {
        System.out.println("#%#$#%#%#%#%#%#%#%#%#%#%#%%%%%%%%%%%%%%%%%%%%"+arg0);
        SpringContext.ctx=arg0;
    }
}