public class EcoreUIUtil
extends java.lang.Object
Modifier and Type | Method and Description |
---|---|
static org.eclipse.emf.common.ui.URIEditorInput |
createURIEditorInput(java.lang.Object object) |
static org.eclipse.ui.IEditorDescriptor |
getDefaultEditor(java.lang.Class<?> type)
Deprecated.
Use
getDefaultEditor(EClass) instead. |
static org.eclipse.ui.IEditorDescriptor |
getDefaultEditor(org.eclipse.emf.ecore.EClass eClass) |
static org.eclipse.ui.IEditorDescriptor |
getDefaultEditor(java.lang.Object object) |
static java.lang.String |
getDummyFileName(java.lang.Class<?> objectType)
Deprecated.
Use
getDummyFileName(EClass) instead. |
static java.lang.String |
getDummyFileName(org.eclipse.emf.ecore.EClass eClass) |
static org.eclipse.ui.IEditorDescriptor[] |
getEditors(org.eclipse.emf.ecore.EClass eClass) |
static org.eclipse.ui.IEditorDescriptor[] |
getEditors(java.lang.Object object)
A convenience method usually used to populate an OpenWithMenu
|
static org.eclipse.core.resources.IFile |
getFileFromEditorInput(org.eclipse.ui.IEditorInput editorInput)
Returns the file behind the editor input
|
static org.eclipse.emf.common.util.URI |
getURIFromEditorInput(org.eclipse.ui.IEditorInput editorInput) |
static void |
openEditor(org.eclipse.ui.IWorkbenchPage page,
java.lang.Object object,
int openStrategy) |
static void |
openEditor(java.lang.Object object,
int openStrategy)
Open the editor using the active workbench page for the given object.
|
static void |
openWizardDialog(org.eclipse.jface.wizard.IWizard wizard) |
static void |
openWizardDialog(org.eclipse.jface.wizard.IWizard wizard,
org.eclipse.emf.transaction.TransactionalEditingDomain editingDomain) |
public static void openEditor(java.lang.Object object, int openStrategy)
OpenStrategy.OPEN_ON_RESOURCE
is
given, the method will retrieve the resource behind the object before opening the editor.object
- The object for which to open the editor or the resource behind it.openStrategy
- A flag to indicate whether to open the editor on the given object or on the resource behind it.OpenStrategy
public static void openEditor(org.eclipse.ui.IWorkbenchPage page, java.lang.Object object, int openStrategy)
public static void openWizardDialog(org.eclipse.jface.wizard.IWizard wizard) throws org.eclipse.core.runtime.OperationCanceledException, org.eclipse.core.commands.ExecutionException
org.eclipse.core.runtime.OperationCanceledException
org.eclipse.core.commands.ExecutionException
public static void openWizardDialog(org.eclipse.jface.wizard.IWizard wizard, org.eclipse.emf.transaction.TransactionalEditingDomain editingDomain) throws org.eclipse.core.runtime.OperationCanceledException, org.eclipse.core.commands.ExecutionException
wizard
- The wizard the dialog to open is supposed to work on.editingDomain
- The transactional editing domain to use for the transaction.org.eclipse.core.runtime.OperationCanceledException
- that is mandatory to force underlying operation to abort without commit if user clicks on the cancel
button.org.eclipse.core.commands.ExecutionException
- if an execution exception occurs.public static org.eclipse.emf.common.ui.URIEditorInput createURIEditorInput(java.lang.Object object)
public static org.eclipse.ui.IEditorDescriptor getDefaultEditor(java.lang.Object object)
public static org.eclipse.ui.IEditorDescriptor[] getEditors(java.lang.Object object)
object
- public static org.eclipse.ui.IEditorDescriptor[] getEditors(org.eclipse.emf.ecore.EClass eClass)
@Deprecated public static java.lang.String getDummyFileName(java.lang.Class<?> objectType)
getDummyFileName(EClass)
instead.public static java.lang.String getDummyFileName(org.eclipse.emf.ecore.EClass eClass)
@Deprecated public static org.eclipse.ui.IEditorDescriptor getDefaultEditor(java.lang.Class<?> type)
getDefaultEditor(EClass)
instead.public static org.eclipse.ui.IEditorDescriptor getDefaultEditor(org.eclipse.emf.ecore.EClass eClass)
public static org.eclipse.emf.common.util.URI getURIFromEditorInput(org.eclipse.ui.IEditorInput editorInput)
public static org.eclipse.core.resources.IFile getFileFromEditorInput(org.eclipse.ui.IEditorInput editorInput)
editorInput
-