Class MemberTransferHandler

  • All Implemented Interfaces:
    java.io.Serializable

    public class MemberTransferHandler
    extends javax.swing.TransferHandler
    A transfer handler that helps with importing / exporting members for relations.
    Since:
    10604
    See Also:
    Serialized Form
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      private static class  MemberTransferHandler.AbstractRelationMemberConverter<T extends PrimitiveId>  
      • Nested classes/interfaces inherited from class javax.swing.TransferHandler

        javax.swing.TransferHandler.DropLocation, javax.swing.TransferHandler.TransferSupport
    • Field Summary

      • Fields inherited from class javax.swing.TransferHandler

        COPY, COPY_OR_MOVE, LINK, MOVE, NONE
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean canImport​(javax.swing.TransferHandler.TransferSupport support)  
      private static int computeInsertionRow​(javax.swing.TransferHandler.TransferSupport support, MemberTable destination)  
      protected java.awt.datatransfer.Transferable createTransferable​(javax.swing.JComponent c)  
      protected void exportDone​(javax.swing.JComponent sourceComponent, java.awt.datatransfer.Transferable data, int action)  
      int getSourceActions​(javax.swing.JComponent c)  
      boolean importData​(javax.swing.TransferHandler.TransferSupport support)  
      protected <T extends PrimitiveId>
      void
      importData​(MemberTable destination, int insertRow, java.util.Collection<T> memberData, MemberTransferHandler.AbstractRelationMemberConverter<T> toMemberFunction)  
      private boolean importDataAt​(javax.swing.TransferHandler.TransferSupport support, MemberTable destination, int insertRow)  
      protected void importPrimitiveData​(javax.swing.TransferHandler.TransferSupport support, MemberTable destination, int insertRow)  
      protected void importRelationMemberData​(javax.swing.TransferHandler.TransferSupport support, MemberTable destination, int insertRow)  
      • Methods inherited from class javax.swing.TransferHandler

        canImport, exportAsDrag, exportToClipboard, getCopyAction, getCutAction, getDragImage, getDragImageOffset, getPasteAction, getVisualRepresentation, importData, setDragImage, setDragImageOffset
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • getSourceActions

        public int getSourceActions​(javax.swing.JComponent c)
        Overrides:
        getSourceActions in class javax.swing.TransferHandler
      • createTransferable

        protected java.awt.datatransfer.Transferable createTransferable​(javax.swing.JComponent c)
        Overrides:
        createTransferable in class javax.swing.TransferHandler
      • canImport

        public boolean canImport​(javax.swing.TransferHandler.TransferSupport support)
        Overrides:
        canImport in class javax.swing.TransferHandler
      • importData

        public boolean importData​(javax.swing.TransferHandler.TransferSupport support)
        Overrides:
        importData in class javax.swing.TransferHandler
      • importDataAt

        private boolean importDataAt​(javax.swing.TransferHandler.TransferSupport support,
                                     MemberTable destination,
                                     int insertRow)
      • importRelationMemberData

        protected void importRelationMemberData​(javax.swing.TransferHandler.TransferSupport support,
                                                MemberTable destination,
                                                int insertRow)
                                         throws java.awt.datatransfer.UnsupportedFlavorException,
                                                java.io.IOException
        Throws:
        java.awt.datatransfer.UnsupportedFlavorException
        java.io.IOException
      • importPrimitiveData

        protected void importPrimitiveData​(javax.swing.TransferHandler.TransferSupport support,
                                           MemberTable destination,
                                           int insertRow)
                                    throws java.awt.datatransfer.UnsupportedFlavorException,
                                           java.io.IOException
        Throws:
        java.awt.datatransfer.UnsupportedFlavorException
        java.io.IOException
      • exportDone

        protected void exportDone​(javax.swing.JComponent sourceComponent,
                                  java.awt.datatransfer.Transferable data,
                                  int action)
        Overrides:
        exportDone in class javax.swing.TransferHandler