01: package org.drools.base;
02:
03: import org.drools.WorkingMemory;
04: import org.drools.spi.Salience;
05: import org.drools.spi.Tuple;
06:
07: public class SalienceInteger implements Salience {
08:
09: /**
10: *
11: */
12: private static final long serialVersionUID = 400L;
13:
14: public static final Salience DEFAULT_SALIENCE = new SalienceInteger(
15: 0);
16:
17: private final int value;
18:
19: public SalienceInteger(int value) {
20: this .value = value;
21: }
22:
23: public int getValue(final Tuple tuple,
24: final WorkingMemory workingMemory) {
25: return this .value;
26: }
27:
28: public String toString() {
29: return String.valueOf(this.value);
30: }
31:
32: }
|