Package org.eclipse.handly.model
Interface IElementHandleFactory
-
public interface IElementHandleFactoryProvides a generic way to createIElementhandles. An instance ofIElementHandleFactoryfor a model can usually be obtained via the model'scontextbycontext.get(IElementHandleFactory.class).Note that, despite having a dependency on
IResource, this interface can safely be used even whenorg.eclipse.core.resourcesbundle is not available. This is based on the "outward impression" of late resolution of symbolic references a JVM must provide according to the JVMS.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description IElementcreateFromHandleMemento(java.lang.String memento)Returns the element handle created from the given handle memento that was generated byElements.getHandleMemento(IElement).IElementcreateFromResourceHandle(org.eclipse.core.resources.IResource resource)Returns the handle of the element corresponding to the given resource.
-
-
-
Method Detail
-
createFromHandleMemento
IElement createFromHandleMemento(java.lang.String memento)
Returns the element handle created from the given handle memento that was generated byElements.getHandleMemento(IElement).- Parameters:
memento- a handle memento (may benull)- Returns:
- the element handle created from the given memento,
or
nullif unable to create an element handle from the given memento
-
createFromResourceHandle
IElement createFromResourceHandle(org.eclipse.core.resources.IResource resource)
Returns the handle of the element corresponding to the given resource.- Parameters:
resource- a resource handle (may benull)- Returns:
- the handle of the element corresponding to the given resource,
or
nullif unable to associate the given resource with an element
-
-