polishing
git-svn-id: https://src.springframework.org/svn/spring-framework/trunk@1979 50f2f4bb-b051-0410-bef5-90022cba6387
This commit is contained in:
parent
3cc2a42bec
commit
c96e42e41e
|
|
@ -95,12 +95,11 @@ import org.springframework.util.ReflectionUtils;
|
||||||
* @since 2.5
|
* @since 2.5
|
||||||
* @see #setAutowiredAnnotationType
|
* @see #setAutowiredAnnotationType
|
||||||
* @see Autowired
|
* @see Autowired
|
||||||
* @see org.springframework.context.annotation.CommonAnnotationBeanPostProcessor
|
|
||||||
*/
|
*/
|
||||||
public class AutowiredAnnotationBeanPostProcessor extends InstantiationAwareBeanPostProcessorAdapter
|
public class AutowiredAnnotationBeanPostProcessor extends InstantiationAwareBeanPostProcessorAdapter
|
||||||
implements MergedBeanDefinitionPostProcessor, PriorityOrdered, BeanFactoryAware {
|
implements MergedBeanDefinitionPostProcessor, PriorityOrdered, BeanFactoryAware {
|
||||||
|
|
||||||
protected final Log logger = LogFactory.getLog(AutowiredAnnotationBeanPostProcessor.class);
|
protected final Log logger = LogFactory.getLog(getClass());
|
||||||
|
|
||||||
private final Set<Class<? extends Annotation>> autowiredAnnotationTypes =
|
private final Set<Class<? extends Annotation>> autowiredAnnotationTypes =
|
||||||
new LinkedHashSet<Class<? extends Annotation>>();
|
new LinkedHashSet<Class<? extends Annotation>>();
|
||||||
|
|
@ -144,7 +143,7 @@ public class AutowiredAnnotationBeanPostProcessor extends InstantiationAwareBean
|
||||||
* Set the 'autowired' annotation type, to be used on constructors, fields,
|
* Set the 'autowired' annotation type, to be used on constructors, fields,
|
||||||
* setter methods and arbitrary config methods.
|
* setter methods and arbitrary config methods.
|
||||||
* <p>The default autowired annotation type is the Spring-provided
|
* <p>The default autowired annotation type is the Spring-provided
|
||||||
* {@link Autowired} annotation.
|
* {@link Autowired} annotation, as well as {@link Value}.
|
||||||
* <p>This setter property exists so that developers can provide their own
|
* <p>This setter property exists so that developers can provide their own
|
||||||
* (non-Spring-specific) annotation type to indicate that a member is
|
* (non-Spring-specific) annotation type to indicate that a member is
|
||||||
* supposed to be autowired.
|
* supposed to be autowired.
|
||||||
|
|
@ -159,8 +158,7 @@ public class AutowiredAnnotationBeanPostProcessor extends InstantiationAwareBean
|
||||||
* Set the 'autowired' annotation types, to be used on constructors, fields,
|
* Set the 'autowired' annotation types, to be used on constructors, fields,
|
||||||
* setter methods and arbitrary config methods.
|
* setter methods and arbitrary config methods.
|
||||||
* <p>The default autowired annotation type is the Spring-provided
|
* <p>The default autowired annotation type is the Spring-provided
|
||||||
* {@link Autowired} annotation, as well as {@link Value} and raw
|
* {@link Autowired} annotation, as well as {@link Value}.
|
||||||
* use of the {@link Qualifier} annotation.
|
|
||||||
* <p>This setter property exists so that developers can provide their own
|
* <p>This setter property exists so that developers can provide their own
|
||||||
* (non-Spring-specific) annotation types to indicate that a member is
|
* (non-Spring-specific) annotation types to indicate that a member is
|
||||||
* supposed to be autowired.
|
* supposed to be autowired.
|
||||||
|
|
@ -299,9 +297,8 @@ public class AutowiredAnnotationBeanPostProcessor extends InstantiationAwareBean
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 'Native' processing method for direct calls with an arbitrary target
|
* 'Native' processing method for direct calls with an arbitrary target instance,
|
||||||
* instance, resolving all of its fields and methods which are annotated
|
* resolving all of its fields and methods which are annotated with <code>@Autowired</code>.
|
||||||
* with <code>@Autowired</code>.
|
|
||||||
* @param bean the target instance to process
|
* @param bean the target instance to process
|
||||||
*/
|
*/
|
||||||
public void processInjection(Object bean) throws BeansException {
|
public void processInjection(Object bean) throws BeansException {
|
||||||
|
|
|
||||||
|
|
@ -59,7 +59,7 @@ import org.springframework.transaction.UnexpectedRollbackException;
|
||||||
*
|
*
|
||||||
* <p>Transaction synchronization is a generic mechanism for registering callbacks
|
* <p>Transaction synchronization is a generic mechanism for registering callbacks
|
||||||
* that get invoked at transaction completion time. This is mainly used internally
|
* that get invoked at transaction completion time. This is mainly used internally
|
||||||
* by the data access support classes for JDBC, Hibernate, JDO, etc when running
|
* by the data access support classes for JDBC, Hibernate, JPA, etc when running
|
||||||
* within a JTA transaction: They register resources that are opened within the
|
* within a JTA transaction: They register resources that are opened within the
|
||||||
* transaction for closing at transaction completion time, allowing e.g. for reuse
|
* transaction for closing at transaction completion time, allowing e.g. for reuse
|
||||||
* of the same Hibernate Session within the transaction. The same mechanism can
|
* of the same Hibernate Session within the transaction. The same mechanism can
|
||||||
|
|
@ -109,7 +109,6 @@ public abstract class AbstractPlatformTransactionManager implements PlatformTran
|
||||||
private static final Constants constants = new Constants(AbstractPlatformTransactionManager.class);
|
private static final Constants constants = new Constants(AbstractPlatformTransactionManager.class);
|
||||||
|
|
||||||
|
|
||||||
/** Transient to optimize serialization */
|
|
||||||
protected transient Log logger = LogFactory.getLog(getClass());
|
protected transient Log logger = LogFactory.getLog(getClass());
|
||||||
|
|
||||||
private int transactionSynchronization = SYNCHRONIZATION_ALWAYS;
|
private int transactionSynchronization = SYNCHRONIZATION_ALWAYS;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue