Package net.datacrow.core.migration.itemimport

Examples of net.datacrow.core.migration.itemimport.ItemImporter


        build();
    }
   
  @Override
    public Object apply() throws WizardException {
        ItemImporter importer = wizard.getDefinition().getImporter();
       
        for (int i = 0; i < table.getRowCount(); i++) {
          String source = (String) table.getValueAt(i, 1, true);
          DcField target = (DcField) table.getValueAt(i, 2, true);
          if (target != null)
            importer.addMapping(source,  target);
        }
        return wizard.getDefinition();
    }
View Full Code Here


          wizard.getDefinition().getFile() != null) {
         
            table.clear();
           
            try {
                ItemImporter reader = wizard.getDefinition().getImporter();
                int veld = 1;
                for (String source : reader.getSourceFields())
                    table.addRow(new Object[] {Integer.valueOf(veld++), source, reader.getTargetField(source)});

            } catch (Exception exp) {
                DcSwingUtilities.displayErrorMessage(DcResources.getText("msgFileCannotBeUsed") + ": " + exp.getMessage());
                logger.error("Error while reading from file", exp);
            }       
View Full Code Here

TOP

Related Classes of net.datacrow.core.migration.itemimport.ItemImporter

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.