Spring Framework InstantiationAwareBeanPostProcessorAdapter - top ranked examples from Open Source projects

These code examples were ranked by Codota’s semantic indexing as the best open source examples for Spring Framework InstantiationAwareBeanPostProcessorAdapter class.

This code example shows how to use the following methods:
 * {@link RepositoryFactoryBeanSupport}s. This is done as shortcut to prevent the need of instantiating 
 * {@link RepositoryFactoryBeanSupport}s just to find out what repository interface they actually create. 
 * @author Oliver Gierke 
class RepositoryInterfaceAwareBeanPostProcessor extends InstantiationAwareBeanPostProcessorAdapter implements
		BeanFactoryAware, PriorityOrdered {
	private static final Logger LOGGER = LoggerFactory.getLogger(RepositoryInterfaceAwareBeanPostProcessor.class); 
	private static final Class<?> REPOSITORY_TYPE = RepositoryFactoryBeanSupport.class;
	private final Map<String, Class<?>> cache = new ConcurrentHashMap<String, Class<?>>();
	private ConfigurableListableBeanFactory context;
	 * (non-Javadoc) 
	 * @see org.springframework.beans.factory.BeanFactoryAware#setBeanFactory(org.springframework.beans.factory.BeanFactory) 
	public void setBeanFactory(BeanFactory beanFactory) {
This code example shows how to use the following methods:
 * <p/> 
 * Will inject either a {@link Compass} or {@link CompassSession} instances. 
 * @author kimchy 
public class CompassContextBeanPostProcessor extends InstantiationAwareBeanPostProcessorAdapter
        implements ApplicationContextAware {
    protected final Log logger = LogFactory.getLog(getClass());
    private ApplicationContext applicationContext;
    private Map<Class<?>, List<AnnotatedMember>> classMetadata = new HashMap<Class<?>, List<AnnotatedMember>>();
    private Map<String, Compass> compassesByName;
    private Compass uniqueCompass;
    public void setApplicationContext(ApplicationContext applicationContext) {
        this.applicationContext = applicationContext;
This code example shows how to use the following methods:
import org.springframework.util.ReflectionUtils;
 * Processes and handles injection for Spring bean properties annotated with {@link Context}. 
public class ContextAnnotationPostProcessor extends InstantiationAwareBeanPostProcessorAdapter implements MergedBeanDefinitionPostProcessor {
    private final Map<Class<?>, InjectionMetadata> cache = new HashMap<>();
    public void postProcessMergedBeanDefinition(RootBeanDefinition beanDefinition, Class<?> beanType, String beanName) {
        if (beanType != null) {
            InjectionMetadata metadata = buildContextMetadata(beanType);
    public PropertyValues postProcessPropertyValues(PropertyValues pvs, PropertyDescriptor[] pds, Object bean, String beanName) throws BeansException {
        InjectionMetadata metadata = getMetadata(bean.getClass());
        try { 
            metadata.inject(bean, beanName, pvs);
        } catch (Throwable ex) {