class UIExporterPajek implements ExporterUI {

    private final ExporterPajekSettings settings = new ExporterPajekSettings();
    private UIExporterPajekPanel panel;
    private ExporterPajek exporterPajek;

    @Override
    public void setup(Exporter exporter) {<FILL_FUNCTION_BODY>}

    @Override
    public void unsetup(boolean update) {
        if (update) {
            panel.unsetup(exporterPajek);
            settings.save(exporterPajek);
        }
        panel = null;
        exporterPajek = null;
    }

    @Override
    public JPanel getPanel() {
        panel = new UIExporterPajekPanel();
        return panel;
    }

    @Override
    public boolean isUIForExporter(Exporter exporter) {
        return exporter instanceof ExporterPajek;
    }

    @Override
    public String getDisplayName() {
        return NbBundle.getMessage(UIExporterPajek.class, "UIExporterPajek.name");
    }

    private static class ExporterPajekSettings extends AbstractExporterSettings {

        // Preferences name
        private final static String EXPORT_POSITION = "Pajek_exportPosition";
        private final static String EXPORT_EDGE_WEIGHT = "Pajek_exportEdgeWeight";
        // Default
        private final static ExporterPajek DEFAULT = new ExporterPajek();

        private void save(ExporterPajek exporterPajek) {
            put(EXPORT_POSITION, exporterPajek.isExportPosition());
            put(EXPORT_EDGE_WEIGHT, exporterPajek.isExportEdgeWeight());
        }

        private void load(ExporterPajek exporterPajek) {
            exporterPajek.setExportPosition(get(EXPORT_POSITION, DEFAULT.isExportPosition()));
            exporterPajek.setExportEdgeWeight(get(EXPORT_EDGE_WEIGHT, DEFAULT.isExportEdgeWeight()));
        }
    }
}

        exporterPajek = (ExporterPajek) exporter;
        settings.load(exporterPajek);
        if (panel != null) {
            panel.setup(exporterPajek);
        }
    
<no_super_class>