Class ImporterDialog

    • Field Detail

      • LAST_IMPORTFILE_PREFERENCE_KEY

        public static final java.lang.String LAST_IMPORTFILE_PREFERENCE_KEY
        See Also:
        Constant Field Values
      • fsrl

        protected FSRL fsrl
      • options

        protected java.util.List<Option> options
      • filenameTextField

        protected javax.swing.JTextField filenameTextField
      • folderButton

        protected javax.swing.JButton folderButton
      • languageButton

        protected javax.swing.JButton languageButton
      • languageTextField

        protected javax.swing.JTextField languageTextField
      • optionsButton

        protected javax.swing.JButton optionsButton
      • folderNameTextField

        protected javax.swing.JTextField folderNameTextField
    • Constructor Detail

      • ImporterDialog

        public ImporterDialog​(PluginTool tool,
                              ProgramManager programManager,
                              LoaderMap loaderMap,
                              ByteProvider byteProvider,
                              java.lang.String suggestedDestinationPath)
        Construct a new dialog for importing a file as a new program into Ghidra.
        Parameters:
        tool - the active tool that spawned this dialog.
        programManager - program manager to open imported file with or null
        loaderMap - the loaders and their corresponding load specifications
        byteProvider - the ByteProvider for getting the bytes from the file to be imported. The dialog takes ownership of the ByteProvider and it will be closed when the dialog is closed
        suggestedDestinationPath - optional string path that will be pre-pended to the destination filename. Any path specified in the destination filename field will be created when the user performs the import (as opposed to the destination folder option which requires the DomainFolder to already exist). The two destination paths work together to specify the final Ghidra project folder where the imported binary is placed.
      • ImporterDialog

        protected ImporterDialog​(java.lang.String title,
                                 PluginTool tool,
                                 LoaderMap loaderMap,
                                 ByteProvider byteProvider,
                                 java.lang.String suggestedDestinationPath)
    • Method Detail

      • setDestinationFolder

        public void setDestinationFolder​(DomainFolder folder)
        Sets the destination folder for the imported program.
        Parameters:
        folder - the folder to store the imported program.
      • isSupported

        protected boolean isSupported​(Loader loader)
      • selectedLoaderChanged

        protected void selectedLoaderChanged()
      • getOptions

        protected java.util.List<Option> getOptions​(LoadSpec loadSpec)
      • getSelectedLoadSpec

        protected LoadSpec getSelectedLoadSpec​(Loader loader)
      • getSelectedLoader

        protected Loader getSelectedLoader()
      • validateFormInput

        protected boolean validateFormInput()