[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Newsgroup Home]
[news.eclipse.modeling.gmf] Re: EMFCoreUtil.getReferencers returns empty set

Vlad,

Since this class is org.eclipse.gmf.runtime.emf.core.util.EMFCoreUtil, this is really a GMF question, and I don't know off hand what might be wrong.


Vlad Ciubotariu wrote:
I forgot to mention the two EReferences have the containment attribute
sent to false.


On Mon, 11 Sep 2006 15:47:05 -0400, Vlad Ciubotariu wrote:

  
I have the following gmf related code:

protected ICommand getDestroyDependentsCommand(DestroyDependentsRequest request) {
		Collection connections = EMFCoreUtil.getReferencers(
				request.getElementToDestroy(),
				new EReference[] { Bluenose2Package.eINSTANCE.getEnd_OutgoingConnections(),
					Bluenose2Package.eINSTANCE.getEnd_IncomingConnections() });
		
		
		

		return request.getDestroyDependentsCommand(connections);
	}

The problem is that connections is always empty, even though the element
to be deleted has connections (confirmed through a separate EMF view).

I haven't done a lot of debugging of why this is happening, I'm hoping
there is a quick fix for this.

thanks for looking
vlad