01: // Copyright (C) 2003,2004,2005 by Object Mentor, Inc. All rights reserved.
02: // Released under the terms of the GNU General Public License version 2 or later.
03: package fitnesse;
04:
05: public class Arguments {
06: public static final String DEFAULT_PATH = ".";
07:
08: public static final String DEFAULT_ROOT = "FitNesseRoot";
09:
10: public static final int DEFAULT_PORT = 80;
11:
12: public static final int DEFAULT_VERSION_DAYS = 14;
13:
14: private String rootPath = DEFAULT_PATH;
15:
16: private int port = DEFAULT_PORT;
17:
18: private String rootDirectory = DEFAULT_ROOT;
19:
20: private String logDirectory;
21:
22: private boolean omitUpdate = false;
23:
24: private int daysTillVersionsExpire = DEFAULT_VERSION_DAYS;
25:
26: private String userpass;
27:
28: public String getRootPath() {
29: return rootPath;
30: }
31:
32: public void setRootPath(String rootPath) {
33: this .rootPath = rootPath;
34: }
35:
36: public int getPort() {
37: return port;
38: }
39:
40: public void setPort(String port) {
41: this .port = Integer.parseInt(port);
42: }
43:
44: public String getRootDirectory() {
45: return rootDirectory;
46: }
47:
48: public void setRootDirectory(String rootDirectory) {
49: this .rootDirectory = rootDirectory;
50: }
51:
52: public String getLogDirectory() {
53: return logDirectory;
54: }
55:
56: public void setLogDirectory(String logDirectory) {
57: this .logDirectory = logDirectory;
58: }
59:
60: public void setOmitUpdates(boolean omitUpdates) {
61: this .omitUpdate = omitUpdates;
62: }
63:
64: public boolean isOmittingUpdates() {
65: return omitUpdate;
66: }
67:
68: public void setUserpass(String userpass) {
69: this .userpass = userpass;
70: }
71:
72: public String getUserpass() {
73: if (userpass == null || userpass.length() == 0)
74: return null;
75: else
76: return userpass;
77: }
78:
79: public int getDaysTillVersionsExpire() {
80: return daysTillVersionsExpire;
81: }
82:
83: public void setDaysTillVersionsExpire(String daysTillVersionsExpire) {
84: this.daysTillVersionsExpire = Integer
85: .parseInt(daysTillVersionsExpire);
86: }
87: }
|