Spring 注解大全

文本来自于:http://rensanning.iteye.com/blog/2362086

(1)Context org.springframework.context.annotation 
@Configuration 
@ComponentScan 
@ComponentScans 
@Conditional 
@Bean 
@Lazy 
@DependsOn 
@Import 
@ImportResource 
@Primary 
@Profile 
@Scope 
@Description 
@PropertySource 
@PropertySources 
@Role 

(2)Bean org.springframework.beans.factory.annotation 
@Autowired 
@Qualifier 
@Required 
@Scope 
@Lookup 
@Value 
@Configurable 

(3)Core org.springframework.core.annotation 
@Order 
@AliasFor 

(4)Stereotyping org.springframework.stereotype 
@Component 
@Controller 
@Service 
@Repository 

(5)Web org.springframework.web.bind.annotation 
@Controller 
@ControllerAdvice 
@InitBinder 
@ModelAttribute 
@MatrixVariable 
@RequestMapping 
@RequestParam 
@RequestPart 
@RequestBody 
@RequestHeader 
@RequestAttribute 
@SessionAttribute 
@SessionAttributes 
@CookieValue 
@ExceptionHandler 
@CrossOrigin 

@GetMapping 
@PostMapping 
@PutMapping 
@DeleteMapping 
@PatchMapping 

@RestController 
@RestControllerAdvice 
@ResponseBody 
@ResponseStatus 
@PathVariable 

(6)Transaction org.springframework.transaction.annotation 
@EnableTransactionManagement 
@Transactional 

(7)Cache org.springframework.cache.annotation 
@EnableCaching 
@CacheConfig 
@Cacheable 
@Caching 
@CachePut 
@CacheEvict 

(8)Schedule org.springframework.scheduling.annotation 
@EnableAsync 
@Async 
@EnableScheduling 
@Scheduled 
@Schedules 

(9)Aspect org.aspectj.lang.annotation 
@Aspect 
@After 
@AfterReturning 
@AfterThrowing 
@Around 
@Before 
@DeclareParents 
@Pointcut 

(10)JSR-250 javax.annotation 
@PostConstruct 
@PreDestroy 
@Resource 

(11)JSR-330 javax.inject 
@Inject 
@Named 

(12)JSR-303 javax.validation.constraints 
@Max 
@Min 
@NotNull 
@Size 
@Pattern 
@Valid 

Hibernate Validator org.hibernate.validator.constraints 
@Email 
@Length 
@Digits 
@NotEmpty 
@NotBlank 
@Range 
@URL 
@Past 
@Future 

(13)MyBatis org.apache.ibatis.annotations 
@Param 
@Select 
@Update 
@Delete 
@Insert 
@Results 
@Result 
@Options 

(14)其他 
@EnableWebMvc org.springframework.web.servlet.config.annotation 
@Validated org.springframework.validation.annotation 
@MapperScan org.mybatis.spring.annotation 
@Alias org.apache.ibatis.type.Alias 
 

SPRING DOC:

http://docs.spring.io/spring-framework/docs/current/javadoc-api/org/springframework/context/annotation/package-summary.html 

Annotation Types Summary部分就是该package下所有注解的说明。 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值