|
Runtime | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface IElementType
Interface used to define application-layer types that describe the kinds of
elements that can be displayed, created, modified and destroyed. These types
extend the types defined for any given metamodel, so that
IElementType
s can be used to distinguish types of elements
that share the same metaclass.
Each element type defines how model objects that match its type are to be displayed (by icon URL and display name), as well as how they are to be created, modified and deleted (by edit helper and an accessor for edit commands).
There are two known extensions of IElementType
. These are
IMetamodelType
and ISpecializationType
. Each
metamodel type maps directly to an EClass. Each specialization type matches a
metamodel type with further restrictions expressed in a
IElementMatcher
class.
Clients should not implement this interface directly, but should extend the
abstract implementation
ElementType
.
Method Summary | |
---|---|
boolean |
canEdit(IEditCommandRequest req)
Answers whether or not the requested edit can be performed. |
IElementType[] |
getAllSuperTypes()
Gets the element supertypes for this type. |
java.lang.String |
getDisplayName()
Gets the display name. |
org.eclipse.emf.ecore.EClass |
getEClass()
Gets the metaclass for this element type. |
ICommand |
getEditCommand(IEditCommandRequest request)
Gets a command to edit an element of this type. |
IEditHelper |
getEditHelper()
Gets the edit helper for this element type. |
java.net.URL |
getIconURL()
Gets the icon URL. |
java.lang.String |
getId()
Gets the unique identifier for this element type. |
Methods inherited from interface org.eclipse.core.runtime.IAdaptable |
---|
getAdapter |
Method Detail |
---|
java.lang.String getId()
java.net.URL getIconURL()
java.lang.String getDisplayName()
org.eclipse.emf.ecore.EClass getEClass()
ICommand getEditCommand(IEditCommandRequest request)
request
- the edit request
null
if none is found. The
command returned may not be executable, and this should be tested
before it is executed.boolean canEdit(IEditCommandRequest req)
req
- the edit request
true
if the requested edit can be performed,
false
otherwise.IEditHelper getEditHelper()
IElementType[] getAllSuperTypes()
|
Runtime | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Guidelines for using Eclipse APIs.
Copyright (c) IBM Corp., Borland Software Corp., and others 2005,2006. All rights reserved.