import java.util.List;
import java.util.Set;
import java.util.SortedSet;
-import java.util.logging.Level;
-import java.util.logging.Logger;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
import javax.swing.BorderFactory;
import javax.swing.DefaultComboBoxModel;
import javax.swing.DropMode;
public class MainFrame extends JFrame {
private static final long serialVersionUID = 1L;
- private static final Logger logger = Logger.getLogger(MainFrame.class.getName());
+ private static final Logger logger = LoggerFactory.getLogger(MainFrame.class);
private final TargetsTableModel targetModel = new TargetsTableModel();
private final TaskManage taskManager;
private final Thread videoFileWatcherThread;
final int row = tblDisplay.getSelectedRow();
final Target t = targetModel.getTarget(row);
final boolean res = taskManager.cancel(t.getRowId());
- logger.log(Level.FINE, "停止: {0} {1}", new Object[]{t.getVideoId(), res});
+ logger.debug("停止: {0} {1}", new Object[]{t.getVideoId(), res});
if (res) {
targetModel.setStatus(t.getRowId(), null, TaskStatus.CANCELLED, -1.0, "キャンセル");
}
final DownloadProfile downProf = new InqubusDownloadProfile();
final String id = Util.getVideoId(cmbId.getText());
final InqubusConvertProfile convProf = new InqubusConvertProfile();
- logger.log(Level.INFO, downProf.toString());
- logger.log(Level.INFO, convProf.toString());
+ logger.debug(downProf.toString());
+ logger.debug(convProf.toString());
final RequestProcess rp = new RequestProcess(downProf, id, convProf);
taskManager.add(rp);
targetModel.addTarget(new Target(rp));
initInputPanel();
} catch (Throwable th) {
- logger.log(Level.SEVERE, null, th);
+ logger.error(null, th);
JOptionPane.showMessageDialog(MainFrame.this, th.getMessage(), "中断しました", JOptionPane.ERROR_MESSAGE);
}
}
try {
p.save();
} catch (ConfigurationException ex) {
- logger.log(Level.SEVERE, "コンフィグ保存失敗", ex);
+ logger.error("コンフィグ保存失敗", ex);
}
}
}