Last change
on this file since 1107 was
922,
checked in by sherbold, 12 years ago
|
- renaming of packages from de.ugoe.cs.quest to de.ugoe.cs.autoquest
|
-
Property svn:executable set to
*
|
File size:
942 bytes
|
Line | |
---|
1 | package de.ugoe.cs.autoquest.tasktrees.nodeequality; |
---|
2 | |
---|
3 | import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskTreeNode; |
---|
4 | |
---|
5 | /** |
---|
6 | * <p> |
---|
7 | * This comparison rule returns <code>NodeEquality.IDENTICAL</code> if the comparison of the two |
---|
8 | * task tree nodes using the <code>==</code> operator or the <code>equals</code> method return true. |
---|
9 | * Else it returns null to denote, that it can not compare the nodes. |
---|
10 | * </p> |
---|
11 | * |
---|
12 | * @version $Revision: $ $Date: 19.02.2012$ |
---|
13 | * @author 2012, last modified by $Author: patrick$ |
---|
14 | */ |
---|
15 | public class NodeIdentityRule implements NodeComparisonRule { |
---|
16 | |
---|
17 | /* |
---|
18 | * (non-Javadoc) |
---|
19 | * |
---|
20 | * @see de.ugoe.cs.tasktree.nodeequality.NodeEqualityRule#apply(TaskTreeNode, TaskTreeNode) |
---|
21 | */ |
---|
22 | @Override |
---|
23 | public NodeEquality compare(ITaskTreeNode node1, ITaskTreeNode node2) { |
---|
24 | if (node1 == node2) { |
---|
25 | return NodeEquality.IDENTICAL; |
---|
26 | } |
---|
27 | else { |
---|
28 | return null; |
---|
29 | } |
---|
30 | } |
---|
31 | |
---|
32 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.