03 2022 档案

摘要:将 service-url改为 serviceUrl驼峰命名法 阅读全文
posted @ 2022-03-31 19:46 dronff 阅读(77) 评论(0) 推荐(0) 编辑
摘要:首先在主配置类中看到了这个注解,点进去可以看到 在点进去第二个之后可以看到 再进去 可以看到引入了一个实现了ImportBeanDefinitionRegistrar接口的类,所以说该类是用来实现自动把主配置类所在包下所有组件注册进容器的 点进Registrar类 这个方法是用来注册的 发现关键代码 阅读全文
posted @ 2022-03-28 20:52 dronff 阅读(17) 评论(0) 推荐(0) 编辑
摘要:(20条消息) 深入理解 Java 中的转义符: \u000a\u0022_墨城之左的博客-CSDN博客 阅读全文
posted @ 2022-03-27 19:53 dronff 阅读(6) 评论(0) 推荐(0) 编辑
摘要:工厂bean一开始放进去的是工厂bean,只有获取的时候才会工厂bean调用方法创建产品对象,放进容器 所以说sqlsessionfactorybean获取得到的是sqlsessionfactory 阅读全文
posted @ 2022-03-27 19:37 dronff 阅读(50) 评论(0) 推荐(0) 编辑
摘要:spring boot使用ServletRegistrationBean<? extends Httpservlet>类对servlet进行了一个封装,容器里面放的是ServletRegistrationBean而不是普通的servlet 阅读全文
posted @ 2022-03-26 21:37 dronff 阅读(47) 评论(0) 推荐(0) 编辑
摘要:今天尝试在router中的beforeEach方法使用pubsub发布消息想要让组件进行响应,但是后来发现无论怎样都没有响应 首先 我在其他普通组件中的mounted钩子上也发布了一个消息,订阅消息的成功响应了,于是我在发布消息,订阅消息之后打印了一下"消息被发布/订阅了",最终发现router发布 阅读全文
posted @ 2022-03-20 20:48 dronff 阅读(110) 评论(0) 推荐(0) 编辑
摘要:vuerouter会从外到里一个一个遍历映射,直到匹配到path与传来的路径相同,然后会从外到里一个个都渲染 阅读全文
posted @ 2022-03-20 16:16 dronff 阅读(4) 评论(0) 推荐(0) 编辑
摘要:当出现这个提示时 可在pom.xml文件中配置 <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-configuration-processor</artifactId> <optiona 阅读全文
posted @ 2022-03-19 21:20 dronff 阅读(493) 评论(0) 推荐(0) 编辑
摘要: 阅读全文
posted @ 2022-03-19 21:20 dronff 阅读(10) 评论(0) 推荐(0) 编辑
摘要:spring boot底层会自动配好配置,但是如果用户配了,就以用户配置的为准。 主要考conditional注解来实现【容器中包含某一类型的bean,且beanname与底层规定的beanname不同,则直接return 这个bean(相当于是创建的一个别名)】 阅读全文
posted @ 2022-03-19 19:46 dronff 阅读(20) 评论(0) 推荐(0) 编辑
摘要:也就是说myStu的参数会自动在容器中找 阅读全文
posted @ 2022-03-19 19:27 dronff 阅读(23) 评论(0) 推荐(0) 编辑
摘要:SpringBoot自动配置原理 - 知乎 (zhihu.com) 阅读全文
posted @ 2022-03-19 17:04 dronff 阅读(9) 评论(0) 推荐(0) 编辑
摘要:(14条消息) spring 的@componentscan, @import, @configuration的个人理解_Tom098的博客-CSDN博客 也就是说 使用import注解不需要使用@Bean或者@Component等一系列组件就能把它们注入到容器中 import注解默认的beanna 阅读全文
posted @ 2022-03-19 16:39 dronff 阅读(37) 评论(0) 推荐(0) 编辑
摘要:输入框取消点击后的加粗边框: outline:none; 文本域取消右下角的拖动三角 resize:none; 阅读全文
posted @ 2022-03-18 16:27 dronff 阅读(51) 评论(0) 推荐(0) 编辑
摘要:盒子相当于原来的位置进行偏移,但是不脱标,只是视觉上进行偏移 阅读全文
posted @ 2022-03-18 14:30 dronff 阅读(14) 评论(0) 推荐(0) 编辑
摘要:float:left如果前面有左浮动,则贴近之前的左浮动的元素的右边缘(放不下则换行),右浮动同理。 可以看成其浮起来了,脱离了标准流,其原先的位置将又其他【后面的】标准流的元素来占有 浮动的元素具有和行内块相似的性质,比如一个块级标签设置浮动后可以设置宽高 阅读全文
posted @ 2022-03-17 21:42 dronff 阅读(16) 评论(0) 推荐(0) 编辑
摘要:两个作用:1.让传进去的类的配置绑定生效 2.将传进去这个类注册到容器中 beanname为全限定名 阅读全文
posted @ 2022-03-17 10:59 dronff 阅读(28) 评论(0) 推荐(0) 编辑
摘要:默认扫描MainApplication类所在的包中的类及其子包 @SpringBootApplication等同于 @SpringBootConfiguration@EnableAutoConfiguration@ComponentScan()所以如果有自己设置扫描包的需求可以改变Component 阅读全文
posted @ 2022-03-16 12:58 dronff 阅读(404) 评论(0) 推荐(0) 编辑
摘要:例如:mysql驱动默认为8.x 如果需要配置自己想要的版本号,则在pom文件中配置 <properties> <mysql.version>5.1.43</mysql.version> </properties> 阅读全文
posted @ 2022-03-15 23:09 dronff 阅读(84) 评论(0) 推荐(0) 编辑
摘要:表示当前controler是直接返回到客户端而不是去请求转发 @ResponseBody @Controller => @RestControler 阅读全文
posted @ 2022-03-15 22:32 dronff 阅读(18) 评论(0) 推荐(0) 编辑
摘要:git init 初始化git项目 git add . 将所有文件添加到暂存区 git commit -m "更新说明" 把暂存区中的内容提交到本地仓库 生成密钥: 在.ssh目录下:ssh-keygen -t rsa命令然后回车回车 阅读全文
posted @ 2022-03-13 13:10 dronff 阅读(18) 评论(0) 推荐(0) 编辑
摘要:Part a = req.getPart("name"); a.write(path+fileName); 注意:如果遇到【由于没有提供multi-part配置,无法处理parts】应添加 @MultipartConfig注解 阅读全文
posted @ 2022-03-13 10:32 dronff 阅读(175) 评论(0) 推荐(0) 编辑
摘要:相当于是不自己去new对象 而是用反射机制去创建类。同时进行功能增强等操作 Sale a = (Sale) Proxy.newProxyInstance(SaleImpl.class.getClassLoader(),SaleImpl.class.getInterfaces(),new NyProx 阅读全文
posted @ 2022-03-13 07:55 dronff 阅读(22) 评论(0) 推荐(0) 编辑
摘要:创建config包 创建MyInterceptor实现HandlerInterCeptor接口 public class MyIntercepter implements HandlerInterceptor { //处理前 @Override public boolean preHandle(Ht 阅读全文
posted @ 2022-03-12 10:23 dronff 阅读(20) 评论(0) 推荐(0) 编辑
摘要:第一步:在spring配置文件中创建datasource数据源 <bean id="datasource" class="org.springframework.jdbc.datasource.DriverManagerDataSource"> <!--配置数据库信息--> </bean> 第二步: 阅读全文
posted @ 2022-03-11 20:12 dronff 阅读(30) 评论(0) 推荐(0) 编辑
摘要:https://blog.csdn.net/li643937579/article/details/109569887 阅读全文
posted @ 2022-03-11 17:40 dronff 阅读(67) 评论(0) 推荐(0) 编辑
摘要:log4j.properties log4j.rootLogger=DEBUG,CONSOLE log4j.logger.demo.mybatis.mydemo2.model=TRACE log4j.appender.CONSOLE=org.apache.log4j.ConsoleAppender 阅读全文
posted @ 2022-03-11 12:00 dronff 阅读(36) 评论(0) 推荐(0) 编辑
摘要:mybatis-config.xml <?xml version="1.0" encoding="UTF-8" ?> <!DOCTYPE configuration PUBLIC "-//mybatis.org//DTD Config 3.0//EN" "http://mybatis.org/dtd 阅读全文
posted @ 2022-03-11 11:18 dronff 阅读(23) 评论(0) 推荐(0) 编辑
摘要:一、提交的域名称与参数名一致 @RequestMapping("/t1") public String t1(int a){ System.out.println(a); return "hello"; } 二、提交的域名称与参数名不一致(使用RequestParam注解) @RequestMapp 阅读全文
posted @ 2022-03-10 20:04 dronff 阅读(31) 评论(0) 推荐(0) 编辑
摘要:方式一: 用springmvc的视图解析器 //返回字符串的话 return "/index.php"; return "/forward:/index.php"; //重定向 return "redirect:/index.php"; ModelView mv = new ModelView(); 阅读全文
posted @ 2022-03-10 19:36 dronff 阅读(204) 评论(0) 推荐(0) 编辑
摘要:注解开发 spring-servlet简化 <beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:context=" 阅读全文
posted @ 2022-03-10 19:18 dronff 阅读(13) 评论(0) 推荐(0) 编辑
摘要:pom文件 导入springmvc框架依赖 <!-- https://mvnrepository.com/artifact/org.springframework/spring-webmvc --> <dependency> <groupId>org.springframework</groupId 阅读全文
posted @ 2022-03-10 19:13 dronff 阅读(36) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示