基于规则系统java,基于规则系统组织业务规则

Constraint

A constraint can be a mandatory restriction or suggested restriction on the behavior of the business event. A mandatory constraint is a complete statement that expresses an unconditional circumstance that must be true or not true for the business event to complete with integrity.

Examples of mandatory constraints are:

A customer must not have more than 10 open orders at one time.

The total dollar amount of a customer order must not be greater than the customer’s single order credit limit amount.

Guideline

A guideline is a complete statement that expresses a warning about a circumstance that should be true or not true. A guideline does not force the circumstance to be true or not true, but merely warns about it, allowing the human to make the decision. Because a guideline only warns and does not reject, it provides a freedom of choice. An example of a guideline is:

A customer should not have more than 10 open orders at one time.

Action enabler

A complete statement that tests conditions and upon finding them true, initiates another business event, message, or other activity. That is, an action enabler initiates a new action external to the scope of the system or increment under study.

Examples of action enablers are:

If a customer order is valid, then initiate the Place Order process.

If a customer is high risk, then notify the customer services manager.

Action-enabler rules can be used in some commercial rules products to create an event-oriented sequence of workflow steps. It may be helpful to think of mandatory constraints and action enablers as opposites. Mandatory constraints stop an event from completing. Action enablers start an event.

Computation

A complete statement that provides an algorithm for arriving at the value of a term where such algorithms may include sum, difference, product, quotient, count, maximum, minimum, average.

An example of a computation rule is:

The total-amount-due for an order is computed as the sum of the lineitem amount(s) for the order plus tax.

Inference

A complete statement that tests conditions and upon finding them true, establishes the truth of a new fact. Examples of inferences are:

If a customer has no outstanding invoices, then the customer is of preferred status.

If a customer is of preferred status, then the customer’s order qualifies for a 20 percent discount.

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值