* @throws IOException
* @see javax.swing.TransferHandler#importData(javax.swing.JComponent,
* java.awt.datatransfer.Transferable)
*/
private boolean importGemEntity(JComponent c, Transferable t) throws UnsupportedFlavorException, IOException {
GemEntity entity = (GemEntity)t.getTransferData(SingleGemEntityDataFlavor.getSingleGemEntityDataFlavor());
AdvancedCALEditor editor = (AdvancedCALEditor)c;
editor.getInputContext().endComposition();
// TODO: If Gem Entities ever contain more than functional agents,
// category needs to be updated
SourceIdentifier.Category category = (entity.isDataConstructor()
? SourceIdentifier.Category.DATA_CONSTRUCTOR
: SourceIdentifier.Category.TOP_LEVEL_FUNCTION_OR_CLASS_METHOD);
editor.replaceSelection(" ");
insertEditorQualification(editor, entity.getName(), category, userQualifiedIdentifiers, false);
return true;
}