1 /******************************************************************************* 2 * Copyright (c) 2004, 2005 IBM Corporation and others. 3 * All rights reserved. This program and the accompanying materials 4 * are made available under the terms of the Eclipse Public License v1.0 5 * which accompanies this distribution, and is available at 6 * http://www.eclipse.org/legal/epl-v10.html 7 * 8 * Contributors: 9 * IBM Corporation - initial API and implementation 10 *******************************************************************************/ 11 package org.eclipse.jface.bindings; 12 13 /** 14 * <p> 15 * The abstract class for any object that can be used as a trigger for a binding. 16 * This ensures that trigger conform to certain minimum requirements. Namely, triggers 17 * need to be hashable. 18 * </p> 19 * 20 * @since 3.1 21 */ 22 public abstract class Trigger implements Comparable { 23 24 /** 25 * Tests whether this object is equal to another object. A handle object is 26 * only equal to another trigger with the same properties. 27 * 28 * @param object 29 * The object with which to compare; may be <code>null</code>. 30 * @return <code>true</code> if the objects are equal; <code>false</code> 31 * otherwise. 32 */ 33 public abstract boolean equals(final Object object); 34 35 /** 36 * Computes the hash code for this object. 37 * 38 * @return The hash code for this object. 39 */ 40 public abstract int hashCode(); 41 } 42