/******************************************************************************* * Copyright (c) 2000, 2008 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.ui; import org.eclipse.jface.resource.ImageDescriptor; /** * Description of an editor in the workbench editor registry. The * editor descriptor contains the information needed to create editor instances. *

* An editor descriptor typically represents one of three types of editors: *

*

*

* This interface is not intended to be implemented or extended by clients. *

* * @see IEditorRegistry * @noimplement This interface is not intended to be implemented by clients. */ public interface IEditorDescriptor extends IWorkbenchPartDescriptor { /** * Returns the editor id. *

* For internal editors, this is the extension id as defined in the workbench * registry; for external editors, it is path and file name of the external * program. *

* * @return the id of the editor */ public String getId(); /** * Returns the descriptor of the image for this editor. * * @return the descriptor of the image to display next to this editor */ public ImageDescriptor getImageDescriptor(); /** * Returns the label to show for this editor. * * @return the editor label */ public String getLabel(); /** * Returns whether this editor descriptor will open a regular editor * part inside the editor area. * * @return true if editor is inside editor area, and * false otherwise * @since 3.0 */ public boolean isInternal(); /** * Returns whether this editor descriptor will open an external * editor in-place inside the editor area. * * @return true if editor is in-place, and false * otherwise * @since 3.0 */ public boolean isOpenInPlace(); /** * Returns whether this editor descriptor will open an external editor * in a new window outside the workbench. * * @return true if editor is external, and false * otherwise * @since 3.0 */ public boolean isOpenExternal(); /** * Returns the editor matching strategy object for editors * represented by this editor descriptor, or null * if there is no explicit matching strategy specified. * * @return the editor matching strategy, or null if none * @since 3.1 */ public IEditorMatchingStrategy getEditorMatchingStrategy(); }