• Spring的Annotation


    <?xml version="1.0" encoding="UTF-8"?>
    <beans xmlns="http://www.springframework.org/schema/beans"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xmlns:context="http://www.springframework.org/schema/context"<!--找到带有context的命名空间的beans,这样才会有语句提示-->
        xsi:schemaLocation="http://www.springframework.org/schema/beans
            http://www.springframework.org/schema/beans/spring-beans.xsd
            http://www.springframework.org/schema/context
            http://www.springframework.org/schema/context/spring-context.xsd">
        
        <!--打开Spring的Annotation支持-->
        <context:annotation-config/>
        <!--设定Spring去哪些包中找Annotation-->
        <context:component-scan base-package="org.example"/>
        
    </beans>
  • 相关阅读:
    Redis Cluter
    数据库设计范式
    kvm虚拟化
    架构前端
    集群架构
    初识shell编程
    网络知识
    Linux三剑客
    Linux磁盘管理
    高性能异步爬虫
  • 原文地址:https://www.cnblogs.com/Akke/p/4947661.html
Copyright © 2020-2023  润新知