001package jmri.jmrit.symbolicprog; 002 003import java.io.File; 004import java.io.IOException; 005import javax.swing.JFrame; 006import javax.swing.JLabel; 007 008/** 009 * Action to import the CV values from a LokProgrammer CV list file. 010 * 011 * @author Bob Jacobsen Copyright (C) 2003 012 * @author Dave Heap Copyright (C) 2015 013 */ 014public class LokProgImportAction extends GenericImportAction { 015 016 public LokProgImportAction(String actionName, CvTableModel pModel, JFrame pParent, JLabel pStatus) { 017 super(actionName, pModel, pParent, pStatus, "LokProgrammer CV list files", "txt", null); 018 } 019 020 @Override 021 boolean launchImporter(File file, CvTableModel tableModel) { 022 try { 023 // ctor launches operation 024 new LokProgImporter(file, mModel); 025 return true; 026 } catch (IOException ex) { 027 return false; 028 } 029 } 030}