|
Runtime | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.eclipse.gmf.runtime.common.core.service.AbstractProvider
org.eclipse.gmf.runtime.emf.ui.services.modelingassistant.ModelingAssistantProvider
public abstract class ModelingAssistantProvider
Abstract class for the Modeling Assistant Provider so that subclasses don't have to override methods they do not provide for. Provides some default behavior.
Constructor Summary | |
---|---|
ModelingAssistantProvider()
|
Method Summary | |
---|---|
java.util.List |
getRelTypesForSREOnSource(IAdaptable source)
Returns the same list of relationship types as getRelTypesOnSource . |
java.util.List |
getRelTypesForSREOnTarget(IAdaptable target)
Returns the same list of relationship types as getRelTypesOnTarget . |
java.util.List |
getRelTypesOnSource(IAdaptable source)
Returns an empty list. |
java.util.List |
getRelTypesOnSourceAndTarget(IAdaptable source,
IAdaptable target)
Returns an empty list. |
java.util.List |
getRelTypesOnTarget(IAdaptable target)
Returns an empty list. |
java.util.List |
getTypes(java.lang.String hint,
IAdaptable data)
Returns an empty list. |
java.util.List |
getTypesForPopupBar(IAdaptable host)
Returns an empty list. |
java.util.List |
getTypesForSource(IAdaptable target,
IElementType relationshipType)
Returns an empty list. |
java.util.List |
getTypesForTarget(IAdaptable source,
IElementType relationshipType)
Returns an empty list. |
boolean |
provides(IOperation operation)
For the Get*TypesFor* operations, this will return true if
the corresponding get*TypesFor* call does not return an
empty list. |
org.eclipse.emf.ecore.EObject |
selectExistingElementForSource(IAdaptable target,
IElementType relationshipType)
Pops up a dialog that allows the user to select an existing element that is to be used as the source in a new relationship being created. |
org.eclipse.emf.ecore.EObject |
selectExistingElementForTarget(IAdaptable source,
IElementType relationshipType)
Returns null. |
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, removeProviderChangeListener |
Constructor Detail |
---|
public ModelingAssistantProvider()
Method Detail |
---|
public boolean provides(IOperation operation)
For the Get*TypesFor*
operations, this will return true if
the corresponding get*TypesFor*
call does not return an
empty list.
For the SelectElementFor*
operations, this will return
true if the corresponding getTypesFor*
call does not
return an empty list.
provides
in interface IProvider
operation
- The operation in question.
true
if this provider provides the operation;
false
otherwise.public java.util.List getTypes(java.lang.String hint, IAdaptable data)
getTypes
in interface IModelingAssistantProvider
hint
- identifies the hint or gesturedata
- IElementType
)public java.util.List getRelTypesForSREOnSource(IAdaptable source)
getRelTypesOnSource
.
getRelTypesForSREOnSource
in interface IModelingAssistantProvider
source
- the source: adapts to editpart, view, element, etc.
IElementType
)public java.util.List getRelTypesForSREOnTarget(IAdaptable target)
getRelTypesOnTarget
.
getRelTypesForSREOnTarget
in interface IModelingAssistantProvider
target
- the target: adapts to editpart, view, element, etc.
IElementType
objects)public java.util.List getRelTypesOnSource(IAdaptable source)
getRelTypesOnSource
in interface IModelingAssistantProvider
source
- the source: adapts to editpart, view, element, etc.
IElementType
)public java.util.List getRelTypesOnTarget(IAdaptable target)
getRelTypesOnTarget
in interface IModelingAssistantProvider
target
- the target: adapts to editpart, view, element, etc.
IElementType
)public java.util.List getRelTypesOnSourceAndTarget(IAdaptable source, IAdaptable target)
getRelTypesOnSourceAndTarget
in interface IModelingAssistantProvider
source
- the source: adapts to editpart, view, element, etc.target
- the target: adapts to editpart, view, element, etc.
IElementType
)public java.util.List getTypesForSource(IAdaptable target, IElementType relationshipType)
getTypesForSource
in interface IModelingAssistantProvider
target
- the target: adapts to editpart, view, element, etc.relationshipType
- the relationship type to be created
IElementType
objects)public java.util.List getTypesForTarget(IAdaptable source, IElementType relationshipType)
getTypesForTarget
in interface IModelingAssistantProvider
source
- the source: adapts to editpart, view, element, etc.relationshipType
- the relationship type to be created
IElementType
objects)public org.eclipse.emf.ecore.EObject selectExistingElementForSource(IAdaptable target, IElementType relationshipType)
IModelingAssistantProvider
selectExistingElementForSource
in interface IModelingAssistantProvider
target
- the target: adapts to editpart, view, element, etc.relationshipType
- the relationship type to be created
EObject
the user selected, or null if
an error occurred or the gesture was cancelled.public org.eclipse.emf.ecore.EObject selectExistingElementForTarget(IAdaptable source, IElementType relationshipType)
selectExistingElementForTarget
in interface IModelingAssistantProvider
source
- the source: adapts to editpart, view, element, etc.relationshipType
- the relationship type to be created
IElement
the user selected, or null if
an error occurred or the gesture was cancelled.public java.util.List getTypesForPopupBar(IAdaptable host)
getTypesForPopupBar
in interface IModelingAssistantProvider
host
- the host on which the popup bar will be displayed: adapts to
editpart, view, element, etc.
IElementType
)
|
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.