You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

25 lines
533 B

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

/**
* 审批规则接口,定义订单审批的规则
*/
package com.orderprocessing;
public interface ApprovalRule {
/**
* 检查订单是否需要审批
* @param order 需要检查的订单
* @return 如果需要审批返回true否则返回false
*/
boolean requiresApproval(Order order);
/**
* 获取审批级别
* @return 审批级别
*/
int getApprovalLevel();
/**
* 获取规则描述
* @return 规则描述
*/
String getDescription();
}