CacheAspectSupport.java 文件源码

java
阅读 27 收藏 0 点赞 0 评论 0

项目:spring 作者:
/**
 * Return a bean with the specified name and type. Used to resolve services that
 * are referenced by name in a {@link CacheOperation}.
 * @param beanName the name of the bean, as defined by the operation
 * @param expectedType type for the bean
 * @return the bean matching that name
 * @throws org.springframework.beans.factory.NoSuchBeanDefinitionException if such bean does not exist
 * @see CacheOperation#keyGenerator
 * @see CacheOperation#cacheManager
 * @see CacheOperation#cacheResolver
 */
protected <T> T getBean(String beanName, Class<T> expectedType) {
    return BeanFactoryAnnotationUtils.qualifiedBeanOfType(this.beanFactory, expectedType, beanName);
}
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号