コード例 #1
0
 private synchronized Settings getSettings() {
   User credentials =
       new User(
           window.getFdUsername().getText(), new String(window.getFdPassword().getPassword()));
   return new Settings(
       credentials,
       (SendMode) window.getCbMode().getSelectedItem(),
       window.getFdHomepage().getText(),
       window.getFdMessage().getText(),
       Integer.parseInt(window.getFdInterval().getText()));
 }
コード例 #2
0
 private boolean hasAllSettings() {
   return !Utils.isNullOrEmpty(window.getFdUsername())
       && !Utils.isNullOrEmpty(window.getFdPassword())
       && !Utils.isNullOrEmpty(window.getFdHomepage())
       && !Utils.isNullOrEmpty(window.getFdMessage());
 }