TblATO_KPIDETAIL.java
1.81 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
package com.sitech.ismp.coll.basic;
import java.io.Serializable;
import java.text.DateFormat;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;
import org.apache.log4j.Logger;
import com.sitech.util.Formater;
public class TblATO_KPIDETAIL implements Serializable {
private static final long serialVersionUID = -8507447462479858823L;
private Logger logger = Logger.getLogger("COLL");
public String UNIT_ID = null;
public String KPI_ID = null;
public String KPI_VALUE = null;
public Date CLL_TIME = null;
public String CLL_TIME_STR = null;
/** 采集周期 */
public String INTERVAL = "0";
public String EXT_INFO = "n/r";
public String toString() {
DateFormat format = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
String str = UNIT_ID + "\t" + KPI_ID + "\t" + KPI_VALUE + "\t"
+ format.format(CLL_TIME) + "\t" + EXT_INFO;
return str;
}
public void display() {
logger.info("-- New KPI:" + this.toString());
}
public void setKPI_ID(String cKPI_ID) throws ParseException {
if (cKPI_ID == null) {
cKPI_ID = "";
}
this.KPI_ID = cKPI_ID;
}
public void setUNIT_ID(String cUNIT_ID) throws ParseException {
if (cUNIT_ID == null) {
cUNIT_ID = "";
}
this.UNIT_ID = cUNIT_ID;
}
public void setCLL_TIME(String cCLL_TIME) throws ParseException {
if (null != cCLL_TIME) {
this.CLL_TIME = Formater.stringToDateTime(cCLL_TIME);
} else {
this.CLL_TIME = new Date();
}
}
public void setCLL_TIME(Date dCLL_TIME) {
this.CLL_TIME = dCLL_TIME;
}
public void setCLL_TIME_STR(Date cll_time) throws Exception {
CLL_TIME_STR = Formater.datetimeToString(cll_time);
}
public void setKPI_VALUE(String cKPI_VALUE) throws ParseException {
if (cKPI_VALUE == null || cKPI_VALUE.length()>2000) {
cKPI_VALUE = "";
}
this.KPI_VALUE = cKPI_VALUE;
}
}