Package com.iizigo.link.java
Class JavaElementLinkAdapter
- java.lang.Object
- com.iizigo.link.java.JavaElementLinkAdapter
 
- All Implemented Interfaces:
- ILinkCapable,- org.eclipse.core.runtime.IAdaptable
 - public class JavaElementLinkAdapter extends java.lang.Object implements ILinkCapable Class used to create an ILinkCapable instance of a Java class.- Author:
- Christopher Mindus
 
- Field Summary- Fields inherited from interface com.iizigo.link.ILinkCapable- STATUS_LINK_NOT_SUPPORTED
 
 - Constructor Summary- Constructors - Constructor - Description - JavaElementLinkAdapter(org.eclipse.jdt.core.IJavaElement element)The constructor.- JavaElementLinkAdapter(org.eclipse.jdt.core.IMethod method)The constructor.- JavaElementLinkAdapter(org.eclipse.jdt.core.IType type)The constructor.
 - Method Summary- All Methods Instance Methods Concrete Methods - Modifier and Type - Method - Description - <T> T- getAdapter(java.lang.Class<T> adapter)Adapter.- java.lang.String- getDragDropText()Gets the link text to display when drag-dropping into JavaScript Panel Editor.- java.util.Collection<ILinkOperation>- getLinkOperations(LinkData data)Called when the drag-drop is to be performed (link or paste-link menu item).- org.eclipse.core.runtime.IStatus- isLinkCapable(LinkData data)Returns if this property container could potentially be link capable.- Methods inherited from class java.lang.Object- clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 - Methods inherited from interface com.iizigo.link.ILinkCapable- getDragDropHTML
 
 
- Constructor Detail- JavaElementLinkAdapter- public JavaElementLinkAdapter(org.eclipse.jdt.core.IMethod method) The constructor.- Parameters:
- method- The method.
 
 - JavaElementLinkAdapter- public JavaElementLinkAdapter(org.eclipse.jdt.core.IType type) The constructor.- Parameters:
- type- The type.
 
 - JavaElementLinkAdapter- public JavaElementLinkAdapter(org.eclipse.jdt.core.IJavaElement element) The constructor.- Parameters:
- element- The Java element.
 
 
 - Method Detail- isLinkCapable- public org.eclipse.core.runtime.IStatus isLinkCapable(LinkData data) Returns if this property container could potentially be link capable.- This call is done many times during drag-drop and must be very fast and not cause too much garbage collection. - Specified by:
- isLinkCapablein interface- ILinkCapable
- Parameters:
- data- The link data.
- Returns:
- The status of capability of the operation.
 
 - getDragDropText- public java.lang.String getDragDropText() Gets the link text to display when drag-dropping into JavaScript Panel Editor.- Specified by:
- getDragDropTextin interface- ILinkCapable
- Returns:
- The drag-drop text to use, or null if the method ILinkCapable.getDragDropHTML()
 
 - getLinkOperations- public java.util.Collection<ILinkOperation> getLinkOperations(LinkData data) Called when the drag-drop is to be performed (link or paste-link menu item). The link-capable instance fills in only what it handles.- Specified by:
- getLinkOperationsin interface- ILinkCapable
- Parameters:
- data- The link data.
- Returns:
- The list of operations required.
 
 - getAdapter- public <T> T getAdapter(java.lang.Class<T> adapter) Adapter.- Specified by:
- getAdapterin interface- org.eclipse.core.runtime.IAdaptable