[927] | 1 | // Copyright 2012 Georg-August-Universität Göttingen, Germany |
---|
| 2 | // |
---|
| 3 | // Licensed under the Apache License, Version 2.0 (the "License"); |
---|
| 4 | // you may not use this file except in compliance with the License. |
---|
| 5 | // You may obtain a copy of the License at |
---|
| 6 | // |
---|
| 7 | // http://www.apache.org/licenses/LICENSE-2.0 |
---|
| 8 | // |
---|
| 9 | // Unless required by applicable law or agreed to in writing, software |
---|
| 10 | // distributed under the License is distributed on an "AS IS" BASIS, |
---|
| 11 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
---|
| 12 | // See the License for the specific language governing permissions and |
---|
| 13 | // limitations under the License. |
---|
[831] | 14 | |
---|
[922] | 15 | package de.ugoe.cs.autoquest.eventcore.guimodel; |
---|
[576] | 16 | |
---|
[778] | 17 | import java.io.Serializable; |
---|
| 18 | |
---|
[576] | 19 | /** |
---|
| 20 | * <p> |
---|
[831] | 21 | * Common interface for GUI element specifications. |
---|
[576] | 22 | * </p> |
---|
| 23 | * |
---|
[831] | 24 | * @version 1.0 |
---|
| 25 | * @author Patrick Harms |
---|
[576] | 26 | */ |
---|
[778] | 27 | public interface IGUIElementSpec extends Serializable { |
---|
[576] | 28 | |
---|
| 29 | /** |
---|
| 30 | * <p> |
---|
[831] | 31 | * Returns a string represenation of the GUI element type that this specification represents. |
---|
[576] | 32 | * </p> |
---|
[831] | 33 | * |
---|
[576] | 34 | * @return |
---|
| 35 | */ |
---|
| 36 | public String getType(); |
---|
[831] | 37 | |
---|
[576] | 38 | /** |
---|
| 39 | * <p> |
---|
[831] | 40 | * Evaluates if two GUI specifications are similar. Similar means that a heuristic determines |
---|
| 41 | * that the two GUI specifications describe the same GUI element. |
---|
[576] | 42 | * </p> |
---|
[831] | 43 | * |
---|
[597] | 44 | * @param other |
---|
[831] | 45 | * specification whose similarity to this is evaluated |
---|
| 46 | * @return true if the specifications are similar; false otherwise |
---|
[576] | 47 | */ |
---|
[597] | 48 | public boolean getSimilarity(IGUIElementSpec other); |
---|
[576] | 49 | |
---|
| 50 | /** |
---|
| 51 | * <p> |
---|
[831] | 52 | * Defines that {@link IGUIElement} implementations have to define equals. |
---|
[576] | 53 | * </p> |
---|
[831] | 54 | * |
---|
| 55 | * @see Object#equals(Object) |
---|
[576] | 56 | */ |
---|
[831] | 57 | @Override |
---|
| 58 | public boolean equals(Object other); |
---|
| 59 | |
---|
[576] | 60 | /** |
---|
| 61 | * <p> |
---|
[831] | 62 | * Defines that {@link IGUIElement} implementations have to define hashCode. |
---|
[576] | 63 | * </p> |
---|
[831] | 64 | * |
---|
| 65 | * @see Object#hashCode() |
---|
[576] | 66 | */ |
---|
[831] | 67 | @Override |
---|
[576] | 68 | public int hashCode(); |
---|
| 69 | } |
---|