1 package edu.uci.iotproject.comparison;
3 import edu.uci.iotproject.Conversation;
4 import edu.uci.iotproject.FlowPattern;
7 * Models the result of comparing a {@link Conversation} and a {@link FlowPattern}.
9 * @param <T> The type of the result; can be something as simple as a {@code Boolean} for a complete match comparison or
10 * or a complex data type for more sophisticated comparisons.
12 public abstract class AbstractPatternComparisonResult<T> {
15 * The result of the comparison.
17 private final T mResult;
20 * The {@code Conversation} that was compared against {@link #mFlowPattern}.
22 protected final Conversation mConversation;
25 * The {@code FlowPattern} that {@link #mConversation} was compared against.
27 protected final FlowPattern mFlowPattern;
29 public AbstractPatternComparisonResult(Conversation conversation, FlowPattern flowPattern, T result) {
30 this.mResult = result;
31 this.mConversation = conversation;
32 this.mFlowPattern = flowPattern;
36 * Gets the result of the comparison.
37 * @return the result of the comparison
39 public T getResult() {
44 * Get a textual description of the comparison result suitable for output on std.out.
45 * @returna a textual description of the comparison result suitable for output on std.out.
47 abstract public String getTextualDescription();