Class ReflectionUtil

java.lang.Object
org.eclipse.graphiti.ui.internal.util.ReflectionUtil

public class ReflectionUtil extends Object
In this class, we combine all reflection code introduced to make Graphiti run in a lean RCP setup, that is, for instance without org.eclipse.ui.ide installed. An alternative would be to use extension points which seems to be rather heavy-weight.
  • Constructor Details

    • ReflectionUtil

      public ReflectionUtil()
  • Method Details

    • getFile

      public static org.eclipse.core.resources.IFile getFile(Object input)
      Typical scenario: input instance of IFileEditorInput We don't want to depend on that interface, as it resides in org.eclipse.ui.ide. We need to support an RCP scenario without having this plug-in installed.
    • getResourceTransfer

      public static org.eclipse.swt.dnd.Transfer getResourceTransfer()
      ResourceTransfer resides in org.eclipse.ui.ide. We need to support an RCP scenario without having this plug-in installed. Therefore ashamed we use dynamic class-loading and reflection.