source: trunk/autoquest-core-events/src/main/java/de/ugoe/cs/autoquest/eventcore/gui/KeyInteraction.java @ 2252

Last change on this file since 2252 was 927, checked in by sherbold, 12 years ago
  • added copyright under the Apache License, Version 2.0
  • Property svn:executable set to *
File size: 1.7 KB
RevLine 
[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.
[786]14
[922]15package de.ugoe.cs.autoquest.eventcore.gui;
[544]16
[922]17import de.ugoe.cs.autoquest.keyboardmaps.VirtualKey;
[544]18
19/**
[786]20 * <p>
21 * Base class for all keyboard interaction event types.
22 * </p>
[544]23 *
[786]24 * @version 1.0
25 * @author Patrick Harms
[544]26 */
27public abstract class KeyInteraction implements IInteraction {
28
[786]29    /**
30     * <p>
31     * Id for object serialization.
32     * </p>
33     */
[544]34    private static final long serialVersionUID = 1L;
35
[786]36    /**
37     * <p>
38     * the key associated with the interaction
39     * </p>
40     */
[550]41    private VirtualKey key;
[544]42
43    /**
[786]44     * <p>
45     * Constructor. Creates a new KeyInteraction.
46     * </p>
47     *
[544]48     * @param key
[786]49     *            key associated with the interaction
[544]50     */
51    public KeyInteraction(VirtualKey key) {
52        super();
[550]53        this.key = key;
[544]54    }
55
56    /**
[786]57     * <p>
58     * Returns the key associated with the interaction.
59     * </p>
[544]60     *
[786]61     * @return the key
[544]62     */
63    public VirtualKey getKey() {
[550]64        return key;
[544]65    }
66
67}
Note: See TracBrowser for help on using the repository browser.