上一页 1 2 3 4 5 6 7 8 ··· 25 下一页
摘要: 1.首先启动SpringAop时,会使用该@EnableAspectJAutoProxy注解 2.将@Import(AspectJAutoProxyRegistrar.class)注入SpringIOC容器中 3.AspectJAutoProxyRegistrar中会注册对象 BeanId:org. 阅读全文
posted @ 2022-08-20 20:16 DiligentCoder 阅读(37) 评论(0) 推荐(0) 编辑
摘要: 使用MySql数据库语法操作update时,第一时间想到的是一下写法: UPDATE purchase_request_detail SET convert_to_voucher_id=2, convert_to_voucher_type='inventory-voucher' WHERE deta 阅读全文
posted @ 2022-08-12 21:07 DiligentCoder 阅读(1183) 评论(1) 推荐(0) 编辑
摘要: 静态代理 由程序创建或者特定工具生成的源代码,在程序运行前,代理类的.class文件已经生成 通过将目标类与代理类实现同一个接口,让代理类持有真实类对 象,然后在代理类方法中调用真实类方法,在调用真实类方法的前 后添加我们所需要的功能扩展代码来达到增强的目的,一句话,自己手写代理类就是静态代理。 p 阅读全文
posted @ 2022-06-26 16:16 DiligentCoder 阅读(109) 评论(0) 推荐(0) 编辑
摘要: 1.创建表 -- Create table create table TEST ( ID NUMBER(10) not null, NAME VARCHAR2(50), SCORE NUMBER(10) ); -- Create/Recreate primary, unique and foreig 阅读全文
posted @ 2022-06-24 14:07 DiligentCoder 阅读(583) 评论(0) 推荐(0) 编辑
摘要: 理解Lamda表达式 确认Lamda表达式的类型 能用 Lamda 表达式来表示的类型,必须是一个函数式接口,而函数式接口,就是只有一个抽象方法的接口。 我们看下非常熟悉的 Runnable 接口在 JDK 中的样子就明白了。 @FunctionalInterface public interfac 阅读全文
posted @ 2022-06-23 15:45 DiligentCoder 阅读(321) 评论(0) 推荐(0) 编辑
摘要: 场景类比 wait/notify的原理 Owner线程发现条件不满足,调用wait方法,即可进入WaitSet变为WAITING BLOCKED和WAITING的线程都处于阻塞状态,不占用CPU时间片 BLOCKED线程会在Owner线程释放锁时唤醒 WATING线程会在Owner线程调用notif 阅读全文
posted @ 2022-06-22 22:43 DiligentCoder 阅读(80) 评论(0) 推荐(0) 编辑
摘要: 一、自定义注解 @Target(ElementType.METHOD) @Retention(RetentionPolicy.RUNTIME) public @interface CopyAsync { } 二、编写AOP切面类 @Aspect @Component public class Cop 阅读全文
posted @ 2022-06-21 22:25 DiligentCoder 阅读(73) 评论(0) 推荐(0) 编辑
摘要: 前言 从Java 5开始,Java提供了Callable接口,该接口是Runnable接口的增强版,Callable接口提供了一个call()方法,可以看作是线程的执行体,但call()方法比run()方法更强大, call()方法可以有返回值,call()方法可以声明抛出异常。 使用代码 publ 阅读全文
posted @ 2022-06-21 21:51 DiligentCoder 阅读(250) 评论(0) 推荐(0) 编辑
摘要: 不错的文章链接: https://blog.csdn.net/foxException/article/details/109008206 阅读全文
posted @ 2022-05-14 11:55 DiligentCoder 阅读(74) 评论(0) 推荐(0) 编辑
摘要: 我们都知道Spring中的BeanFactory是一个IOC容器,负责创建Bean和缓存一些单例的Bean对象,以供项目运行过程中使用。创建Bean的大概的过程:实例化Bean对象,为Bean对象在内存中分配空间,各属性赋值为默认值初始化Bean对象,为Bean对象填充属性将Bean放入缓存首先,容 阅读全文
posted @ 2022-05-13 00:43 DiligentCoder 阅读(32) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 7 8 ··· 25 下一页