huangcm
2025-04-09 02d4ce54b909bd733f12e9f3fa4c1b03cf2d6f45
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
81
82
83
84
85
86
87
88
package com.DeviceTest.helper;
 
import java.io.IOException;
import java.io.Serializable;
 
public class TestCase implements Serializable {
   public static enum RESULT {
        NG, OK, SKIP, UNDEF,
   }
 
   private int testNo;
   private boolean needtest;
   private String testName;
   private String className;
   private RESULT result = RESULT.UNDEF;
   private String detail;
   private boolean showResult;
 
   public boolean isShowResult() {
       return showResult;
   }
 
   public void setShowResult(boolean showResult) {
       this.showResult = showResult;
   }
 
   public String getDetail() {
       return detail;
   }
 
   public void setDetail(String detail) {
       this.detail = detail;
   }
 
   public TestCase(int testNo, String testName, String className) {
       this.testNo = testNo;
       this.testName = testName;
       this.className = className;
       this.needtest = true;
       showResult = true;
   }
   public boolean getneedtest(){
       return this.needtest;
   }
   public void setneedtest(boolean tmp){
       this.needtest = tmp;
   }
   public String getClassName() {
       return className;
   }
 
   public RESULT getResult() {
       return result;
   }
 
   public String getTestName() {
       return testName;
   }
 
   public int getTestNo() {
       return testNo;
   }
 
   public void setResult(RESULT result) {
       this.result = result;
   }
 
   private void writeObject(java.io.ObjectOutputStream out) throws IOException {
       out.writeObject(className);
       out.writeInt(result.ordinal());
       out.writeObject(detail);
       out.writeBoolean(showResult);
   }
 
   private void readObject(java.io.ObjectInputStream in) throws IOException,
           ClassNotFoundException {
        Object object = in.readObject();
        if (null != object) {
            className = object.toString();
        }
        result = RESULT.values()[in.readInt()];
        object = in.readObject();
        if (null != object) {
            detail = object.toString();
        }
        showResult = in.readBoolean();
   }
}