1 11 package org.eclipse.ltk.internal.ui.refactoring.history; 12 13 14 19 public final class RefactoringHistoryDate extends RefactoringHistoryNode { 20 21 22 private final int fKind; 23 24 25 private final RefactoringHistoryNode fParent; 26 27 28 private final long fStamp; 29 30 40 public RefactoringHistoryDate(final RefactoringHistoryNode parent, final long stamp, final int kind) { 41 fParent= parent; 42 fStamp= stamp; 43 fKind= kind; 44 } 45 46 49 public boolean equals(final Object object) { 50 if (object instanceof RefactoringHistoryDate) { 51 final RefactoringHistoryDate node= (RefactoringHistoryDate) object; 52 return super.equals(object) && getTimeStamp() == node.getTimeStamp() && getKind() == node.getKind(); 53 } 54 return false; 55 } 56 57 60 public int getKind() { 61 return fKind; 62 } 63 64 67 public RefactoringHistoryNode getParent() { 68 return fParent; 69 } 70 71 76 public long getTimeStamp() { 77 return fStamp; 78 } 79 80 83 public int hashCode() { 84 return (int) (super.hashCode() + 17 * getKind() + 31 * getTimeStamp()); 85 } 86 } 87 | Popular Tags |