Package org.gephi.io.importer.spi
Interface ImporterUI
-
public interface ImporterUIDefine importer settings user interface.Declared in the system as services (i.e. singleton), the role of UI classes is to provide user interface to configure importers and remember last used settings if needed.
To be recognized by the system, implementations must just add the following annotation:
@ServiceProvider(service=ImporterUI.class)
- Author:
- Mathieu Bastian
- See Also:
Importer
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interfaceImporterUI.WithWizardOptional interface to implement forImporterUIclasses that need a Wizard
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description StringgetDisplayName()Returns the importer display nameJPanelgetPanel()Returns the importer settings panel.booleanisUIForImporter(Importer importer)Returnstrueif this UI belongs to the given importer.voidsetup(Importer[] importers)Link the UI to the importers and therefore to settings values.voidunsetup(boolean update)Notify UI the settings panel has been closed and that new values can be written.
-
-
-
Method Detail
-
setup
void setup(Importer[] importers)
Link the UI to the importers and therefore to settings values. This method is called aftergetPanel()to push settings.- Parameters:
importers- the importers that settings is to be set
-
getPanel
JPanel getPanel()
Returns the importer settings panel.- Returns:
- a settings panel, or
null
-
unsetup
void unsetup(boolean update)
Notify UI the settings panel has been closed and that new values can be written.- Parameters:
update-trueif user clicked OK orfalseif CANCEL.
-
getDisplayName
String getDisplayName()
Returns the importer display name- Returns:
- the importer display name
-
isUIForImporter
boolean isUIForImporter(Importer importer)
Returnstrueif this UI belongs to the given importer.- Parameters:
importer- the importer that has to be tested- Returns:
trueif the UI is matching withimporter,falseotherwise.
-
-