1 21 22 25 package net.sf.launch4j.config; 26 27 import java.io.File ; 28 29 import net.sf.launch4j.binding.IValidatable; 30 import net.sf.launch4j.binding.Validator; 31 32 35 public class Splash implements IValidatable { 36 37 public static final String SPLASH_FILE = "splash"; 39 public static final String WAIT_FOR_TITLE = "waitForTitle"; 40 public static final String TIMEOUT = "splashTimeout"; 41 public static final String TIMEOUT_ERR = "splashTimeoutErr"; 42 43 private File file; 45 private boolean waitForWindow = true; 46 private int timeout = 60; 47 private boolean timeoutErr = true; 48 49 public void checkInvariants() { 50 Validator.checkFile(file, "splash.file", 51 Messages.getString("Splash.splash.file")); 52 Validator.checkRange(timeout, 1, 60 * 15, "splash.timeout", 53 Messages.getString("Splash.splash.timeout")); 54 } 55 56 57 public File getFile() { 58 return file; 59 } 60 61 public void setFile(File file) { 62 this.file = file; 63 } 64 65 66 public int getTimeout() { 67 return timeout; 68 } 69 70 public void setTimeout(int timeout) { 71 this.timeout = timeout; 72 } 73 74 75 public boolean isTimeoutErr() { 76 return timeoutErr; 77 } 78 79 public void setTimeoutErr(boolean timeoutErr) { 80 this.timeoutErr = timeoutErr; 81 } 82 83 84 public boolean getWaitForWindow() { 85 return waitForWindow; 86 } 87 88 public void setWaitForWindow(boolean waitForWindow) { 89 this.waitForWindow = waitForWindow; 90 } 91 } 92 | Popular Tags |