/** * Copyright (c) 2008, 2015 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/epl-v10.html * * Contributors: * IBM Corporation - initial API and implementation */ package org.eclipse.e4.ui.model.application.ui.menu; import org.eclipse.e4.ui.model.application.ui.MUIElement; import org.eclipse.e4.ui.model.application.ui.MUILabel; /** * <!-- begin-user-doc --> * A representation of the model object '<em><b>Item</b></em>'. * <!-- end-user-doc --> * * <!-- begin-model-doc --> * <p> * This is the base type for various menu and toolbar items. * </p> * @since 1.0 * @noimplement This interface is not intended to be implemented by clients. * <!-- end-model-doc --> * * <p> * The following features are supported: * </p> * <ul> * <li>{@link org.eclipse.e4.ui.model.application.ui.menu.MItem#isEnabled <em>Enabled</em>}</li> * <li>{@link org.eclipse.e4.ui.model.application.ui.menu.MItem#isSelected <em>Selected</em>}</li> * <li>{@link org.eclipse.e4.ui.model.application.ui.menu.MItem#getType <em>Type</em>}</li> * </ul> * * @model abstract="true" * @generated */ public interface MItem extends MUIElement, MUILabel { /** * Returns the value of the '<em><b>Enabled</b></em>' attribute. * The default value is <code>"true"</code>. * <!-- begin-user-doc --> * <!-- end-user-doc --> * <!-- begin-model-doc --> * <p> * Defines the current enablement state of a given menu or toolbar item. * </p> * <!-- end-model-doc --> * @return the value of the '<em>Enabled</em>' attribute. * @see #setEnabled(boolean) * @model default="true" * @generated */ boolean isEnabled(); /** * Sets the value of the '{@link org.eclipse.e4.ui.model.application.ui.menu.MItem#isEnabled <em>Enabled</em>}' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @param value the new value of the '<em>Enabled</em>' attribute. * @see #isEnabled() * @generated */ void setEnabled(boolean value); /** * Returns the value of the '<em><b>Selected</b></em>' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> * <!-- begin-model-doc --> * <p> * Defines the current selection state for a menu or tool item * </p> * <!-- end-model-doc --> * @return the value of the '<em>Selected</em>' attribute. * @see #setSelected(boolean) * @model * @generated */ boolean isSelected(); /** * Sets the value of the '{@link org.eclipse.e4.ui.model.application.ui.menu.MItem#isSelected <em>Selected</em>}' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @param value the new value of the '<em>Selected</em>' attribute. * @see #isSelected() * @generated */ void setSelected(boolean value); /** * Returns the value of the '<em><b>Type</b></em>' attribute. * The literals are from the enumeration {@link org.eclipse.e4.ui.model.application.ui.menu.ItemType}. * <!-- begin-user-doc --> * <!-- end-user-doc --> * <!-- begin-model-doc --> * <p> * Defines the item type for this item. * </p> * <!-- end-model-doc --> * @return the value of the '<em>Type</em>' attribute. * @see org.eclipse.e4.ui.model.application.ui.menu.ItemType * @see #setType(ItemType) * @model required="true" * @generated */ ItemType getType(); /** * Sets the value of the '{@link org.eclipse.e4.ui.model.application.ui.menu.MItem#getType <em>Type</em>}' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @param value the new value of the '<em>Type</em>' attribute. * @see org.eclipse.e4.ui.model.application.ui.menu.ItemType * @see #getType() * @generated */ void setType(ItemType value); } // MItem