Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
Copyright (c) 2004 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 Contributors: IBM Corporation - initial API and implementation /
The operation used with the modeling assistant service that pops up a dialog from which the user can select an existing element to be used as the source end of a relationship.

the target: adapts to editpart, view, element, etc.
	private final IAdaptable target;

the relationship type to be created
	private final IElementType relationshipType;

Creates a new GetTypesForSourceOperation.

target the target: adapts to editpart, view, element, etc.
relationshipType the relationship type to be created
			IElementType relationshipType) {
		this. = target;
		this. = relationshipType;
	/* (non-Javadoc)
	 * @see
	public String getId() {

Returns the target. This is what will be used to assist in delayed loading of a modeling assistant provider.
	public IAdaptable getContext() {
		return getTarget();
	/* (non-Javadoc)
	 * @see org.eclipse.gmf.runtime.common.core.service.IOperation#execute(org.eclipse.gmf.runtime.common.core.service.IProvider)
	public Object execute(IProvider provider) {
		return ((IModelingAssistantProviderprovider)

Gets the relationshipType.

Returns the relationshipType.

Gets the target.

Returns the target.
	public IAdaptable getTarget() {
		return ;
New to GrepCode? Check out our FAQ X