KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > net > sourceforge > tracelog > config > LogFile


1 package net.sourceforge.tracelog.config;
2
3 import java.io.Serializable JavaDoc;
4
5 import net.sourceforge.tracelog.utils.Util;
6
7 /**
8  * LogFile is a value object that contains information about the log, such as
9  * log name, log file path and the color of log text (when displayed).
10  *
11  * @author Choon-Chern Lim (Mike)
12  */

13 public class LogFile implements Serializable JavaDoc {
14     private static final long serialVersionUID = 5339819668361806191L;
15     public int logOrder;
16     public int foregroundColor;
17     public int backgroundColor;
18     public String JavaDoc logName;
19     public String JavaDoc logPath;
20     public String JavaDoc id;
21
22     public LogFile() {
23         this(0, "", "", 0, 0);
24     }
25
26     public LogFile(int logOrder, String JavaDoc logName, String JavaDoc logPath, int foregroundColor, int backgroundColor) {
27         this.logOrder = logOrder;
28         this.logName = logName;
29         this.logPath = logPath;
30         this.foregroundColor = foregroundColor;
31         this.backgroundColor = backgroundColor;
32         this.id = Util.getUniqueId();
33     }
34
35     /**
36      * @return the backgroundColor
37      */

38     public int getBackgroundColor() {
39         return backgroundColor;
40     }
41
42     /**
43      * @param backgroundColor
44      * the backgroundColor to set
45      */

46     public void setBackgroundColor(int backgroundColor) {
47         this.backgroundColor = backgroundColor;
48     }
49
50     /**
51      * @return the foregroundColor
52      */

53     public int getForegroundColor() {
54         return foregroundColor;
55     }
56
57     /**
58      * @param foregroundColor
59      * the foregroundColor to set
60      */

61     public void setForegroundColor(int foregroundColor) {
62         this.foregroundColor = foregroundColor;
63     }
64
65     /**
66      * @return the id
67      */

68     public String JavaDoc getId() {
69         return id;
70     }
71
72     /**
73      * @param id
74      * the id to set
75      */

76     public void setId(String JavaDoc id) {
77         this.id = id.trim();
78     }
79
80     /**
81      * @return the logName
82      */

83     public String JavaDoc getLogName() {
84         return logName;
85     }
86
87     /**
88      * @param logName
89      * the logName to set
90      */

91     public void setLogName(String JavaDoc logName) {
92         this.logName = logName.trim();
93     }
94
95     /**
96      * @return the logOrder
97      */

98     public int getLogOrder() {
99         return logOrder;
100     }
101
102     /**
103      * @param logOrder
104      * the logOrder to set
105      */

106     public void setLogOrder(int logOrder) {
107         this.logOrder = logOrder;
108     }
109
110     /**
111      * @return the logPath
112      */

113     public String JavaDoc getLogPath() {
114         return logPath;
115     }
116
117     /**
118      * @param logPath
119      * the logPath to set
120      */

121     public void setLogPath(String JavaDoc logPath) {
122         this.logPath = logPath.trim();
123     }
124
125 }
126
Popular Tags