25 lines
		
	
	
		
			773 B
		
	
	
	
		
			Java
		
	
	
	
	
	
		
		
			
		
	
	
			25 lines
		
	
	
		
			773 B
		
	
	
	
		
			Java
		
	
	
	
	
	
|   | package com.upchina.common.annotation;
 | |||
|  | 
 | |||
|  | import com.upchina.common.constant.ProductType;
 | |||
|  | 
 | |||
|  | import java.lang.annotation.*;
 | |||
|  | 
 | |||
|  | @Target({ElementType.METHOD}) // 作用在方法上
 | |||
|  | @Retention(RetentionPolicy.RUNTIME) // 注解会在class字节码文件中存在,在运行时可以通过反射获取到
 | |||
|  | @Documented // 说明该注解将被包含在javadoc中
 | |||
|  | public @interface Operation {
 | |||
|  | 
 | |||
|  |     // 业务类型:0投顾 1观点包 2单篇观点 3视频产品类型:5交易圈 6图文直播 7组合 8锦囊
 | |||
|  |     ProductType module() default ProductType.ADVISOR_INFO;
 | |||
|  | 
 | |||
|  |     // 业务对象主键id的key
 | |||
|  |     String idKey() default "id";
 | |||
|  | 
 | |||
|  |     // 业务对象状态的key
 | |||
|  |     String statusKey() default "status";
 | |||
|  | 
 | |||
|  |     // 操作理由的key
 | |||
|  |     String reasonKey() default "reason";
 | |||
|  | 
 | |||
|  | }
 |