Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com
Answertopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 

Runtime

org.eclipse.gmf.runtime.common.ui.services.editor
Class EditorService

java.lang.Object
  extended by 

org.eclipse.gmf.runtime.common.core.service.AbstractProvider
      extended by 

org.eclipse.gmf.runtime.common.core.service.Service
          extended by 
org.eclipse.gmf.runtime.common.ui.services.editor.EditorService
All Implemented Interfaces:
java.util.EventListener, IProvider, IProviderChangeListener, IEditorProvider

public class EditorService
extends Service
implements IEditorProvider

A service for manipulating editors


Nested Class Summary
 
Nested classes/interfaces inherited from class org.eclipse.gmf.runtime.common.core.service. Service
Service.ProviderDescriptor
 
Field Summary
 
Fields inherited from class org.eclipse.gmf.runtime.common.core.service. Service
INVALID_ELEMENT_MESSAGE_PATTERN
 
Constructor Summary
protected EditorService ()
          Constructs a new editor service.
 
Method Summary
protected  java.util.Map getEditorsMap ()
          Returns the editorsMap.
static  EditorService getInstance ()
          Retrieves the singleton instance of the editor service.
 java.util.List getRegisteredEditorParts ()
          Return a list of all editor parts
 java.util.List getRegisteredEditors (java.lang.String editorId)
          Returns all registered editors with given id
  IEditorPart openEditor ( IEditorInput editorInput)
          Opens an editor with the given editor input
 void registerEditor ( IEditorPart editor)
          Method registerEditor registers the editor with the editor service should be called by the editor upon initialization
 void unregisterEditor ( IEditorPart editor)
          Method unregisterEditor unregisters the editor from the editor service should be called by the editor upon getting disposed
 
Methods inherited from class org.eclipse.gmf.runtime.common.core.service. Service
addProvider, clearCache, configureProviders, configureProviders, createPriorityCache, execute, executeUnique, getAllProviders, getCachingKey, getPriority, getProviders, isOptimistic, isOptimized, newProviderDescriptor, providerChanged, provides, provides, removeProvider
 
Methods inherited from class org.eclipse.gmf.runtime.common.core.service. AbstractProvider
addProviderChangeListener, fireProviderChange, removeProviderChangeListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.eclipse.gmf.runtime.common.core.service. IProvider
addProviderChangeListener, provides, removeProviderChangeListener
 

Constructor Detail

EditorService

protected EditorService()
Constructs a new editor service.

Method Detail

getInstance

public static 
EditorService getInstance()
Retrieves the singleton instance of the editor service.

Returns:
The editor service singleton.

openEditor

public 
IEditorPart openEditor(
IEditorInput editorInput)
Opens an editor with the given editor input

Specified by:
openEditor in interface IEditorProvider
Parameters:
editorInput - the editor input object
Returns:
the opened IEditorPart
See Also:
IEditorProvider.openEditor(IEditorInput)

getEditorsMap

protected java.util.Map getEditorsMap()
Returns the editorsMap.

Returns:
Map of editors

registerEditor

public void registerEditor(
IEditorPart editor)
Method registerEditor registers the editor with the editor service should be called by the editor upon initialization

Parameters:
editor - to be registered in the editor service

unregisterEditor

public void unregisterEditor(
IEditorPart editor)
Method unregisterEditor unregisters the editor from the editor service should be called by the editor upon getting disposed

Parameters:
editor - to unregister from the editor service

getRegisteredEditors

public java.util.List getRegisteredEditors(java.lang.String editorId)
Returns all registered editors with given id

Parameters:
editorId - returned editors must have this String id
Returns:
List editors matching the String editorId

getRegisteredEditorParts

public java.util.List getRegisteredEditorParts()
Return a list of all editor parts

Returns:
List of IEditorPart editors.

Runtime

Guidelines for using Eclipse APIs.

Copyright (c) IBM Corp., Borland Software Corp., and others 2005,2006. All rights reserved.


 
 
  Published under the terms of the Eclipse Public License Version 1.0 ("EPL") Design by Interspire