Skip to content

Commit e0d6ceb

Browse files
committed
Add DropBeanBeforeInit.java
1 parent 83f8476 commit e0d6ceb

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
package spring.oldboy.bean_post_processor;
2+
3+
import java.lang.annotation.ElementType;
4+
import java.lang.annotation.Retention;
5+
import java.lang.annotation.RetentionPolicy;
6+
import java.lang.annotation.Target;
7+
8+
/*
9+
Поскольку наша аннотация нужна будет в RunTime, то RetentionPolicy.RUNTIME,
10+
т.к. по умолчанию RetentionPolicy.CLASS. Аннотация @Target указывает над чем
11+
будет использоваться наша аннотация - над классом (TYPE).
12+
*/
13+
@Retention(RetentionPolicy.RUNTIME)
14+
@Target(ElementType.TYPE)
15+
public @interface DropBeanBeforeInit {
16+
/*
17+
Суть данной аннотации показать, что может быть
18+
при внедрении подмены до этапа инициализации bean-a
19+
*/
20+
}

0 commit comments

Comments
 (0)