Sunshine
2024-11-04 7f1a0e49c1fe0c3f9f8a2493f30451d90b62ab64
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
package com.nova.sankuai.infra.utils.baofu.http;
 
import com.nova.sankuai.infra.utils.baofu.HttpUtil;
 
import java.io.Serializable;
 
/**
 * 项目名称:baofoo-fopay-sdk-java
 * 类名称:表单参数
 * 类描述:
 * 创建人:陈少杰
 * 创建时间:2014-10-22 下午2:58:22
 * 修改人:陈少杰
 * 修改时间:2014-10-22 下午2:58:22
 * @version
 */
public class SimpleHttpResponse implements Serializable {
 
    /**
     * 
     */
    private static final long serialVersionUID = 1L;
 
    private int statusCode;
    private String entityString;
    private String errorMessage;
 
    /**
     * @param statusCode
     * @param entityString
     */
    public SimpleHttpResponse(int statusCode, String entityString,
            String errorMessage) {
        super();
        this.statusCode = statusCode;
        this.entityString = entityString;
        this.errorMessage = errorMessage;
    }
 
    /**
     * 是否成功
     * 
     * @return
     */
    public boolean isRequestSuccess() {
        return HttpUtil.isRequestSuccess(statusCode);
    }
 
    /**
     * @return the statusCode
     */
    public int getStatusCode() {
        return statusCode;
    }
 
    /**
     * @return the entityString
     */
    public String getEntityString() {
        return entityString;
    }
 
    /**
     * @return the errorMessage
     */
    public String getErrorMessage() {
        return errorMessage;
    }
 
}