1 /*******************************************************************************
2 * Copyright (c) 2000, 2017 IBM Corporation and others.
4 * This program and the accompanying materials
5 * are made available under the terms of the Eclipse Public License 2.0
6 * which accompanies this distribution, and is available at
7 * https://www.eclipse.org/legal/epl-2.0/
9 * SPDX-License-Identifier: EPL-2.0
12 * IBM Corporation - initial API and implementation
13 *******************************************************************************/
14 package org.eclipse.swt.events;
17 * This adapter class provides default implementations for the
18 * methods described by the <code>ExpandListener</code> interface.
20 * Classes that wish to deal with <code>ExpandEvent</code>s can
21 * extend this class and override only the methods which they are
25 * An alternative to this class are the static helper methods
26 * {@link ExpandListener#itemCollapsedAdapter(java.util.function.Consumer)}
28 * {@link ExpandListener#itemExpandedAdapter(java.util.function.Consumer)},
29 * which accept a lambda expression or a method reference that implements the event consumer.
34 * @see <a href="http://www.eclipse.org/swt/">Sample code and further information</a>
38 public abstract class ExpandAdapter implements ExpandListener {
41 * Sent when an item is collapsed.
42 * The default behavior is to do nothing.
44 * @param e an event containing information about the operation
47 public void itemCollapsed(ExpandEvent e) {
51 * Sent when an item is expanded.
52 * The default behavior is to do nothing.
54 * @param e an event containing information about the operation
57 public void itemExpanded(ExpandEvent e) {