-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathRestifizerResponse.cs
42 lines (38 loc) · 1.09 KB
/
RestifizerResponse.cs
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
using UnityEngine;
using System.Collections;
using UnityHTTP;
namespace Restifizer {
public class RestifizerResponse {
public bool IsList;
public bool HasError;
public Hashtable Resource;
public ArrayList ResourceList;
public RestifizerError Error;
public int Status;
public string Tag;
public UnityHTTP.Request Request;
public RestifizerResponse(UnityHTTP.Request request, Hashtable result, string tag) {
this.IsList = false;
this.Status = request.response.status;
this.Resource = result;
this.HasError = false;
this.Request = request;
this.Tag = tag;
}
public RestifizerResponse(UnityHTTP.Request request, ArrayList result, string tag) {
this.IsList = true;
this.Status = request.response.status;
this.ResourceList = result;
this.HasError = false;
this.Request = request;
this.Tag = tag;
}
public RestifizerResponse(UnityHTTP.Request request, RestifizerError error, string tag) {
this.Status = request.response.status;
this.HasError = true;
this.Error = error;
this.Request = request;
this.Tag = tag;
}
}
}