1 package net.sourceforge.cruisecontrol.publishers.sfee; 2 3 import net.sourceforge.cruisecontrol.CruiseControlException; 4 import net.sourceforge.cruisecontrol.Publisher; 5 import net.sourceforge.cruisecontrol.util.ValidationHelper; 6 7 public abstract class SfeePublisher implements Publisher { 8 private String url; 9 private String username; 10 private String password; 11 12 public String getServerURL() { 13 return url; 14 } 15 16 public String getUsername() { 17 return username; 18 } 19 20 public String getPassword() { 21 return password; 22 } 23 24 public void setServerURL(String url) { 25 this.url = url; 26 } 27 28 public void setUsername(String username) { 29 this.username = username; 30 } 31 32 public void setPassword(String password) { 33 this.password = password; 34 } 35 36 public final void validate() throws CruiseControlException { 37 ValidationHelper.assertIsSet(url, "serverurl", this.getClass()); 38 ValidationHelper.assertIsSet(username, "username", this.getClass()); 39 ValidationHelper.assertIsSet(password, "password", this.getClass()); 40 41 subValidate(); 42 } 43 44 public abstract void subValidate() throws CruiseControlException; 45 } 46 | Popular Tags |