1: <?php
2: namespace Hyperwallet\Model;
3:
4: /**
5: * Represents a V4 HyperwalletVerificationDocument
6: *
7: * @property string $category The category of the document
8: * @property string $type The type of the document
9: * @property string $status The status of the document
10: * @property string $country The country origin of the document
11: * @property HyperwalletVerificationDocumentReasonCollection $reasons The reasons for the documents rejection of type HyperwalletVerificationDocumentReasons
12: * @property \DateTime $createdOn The document creation date
13: * @property object $uploadFiles The files uploaded
14: *
15: * @package Hyperwallet\Model
16: */
17: class HyperwalletVerificationDocument extends BaseModel {
18:
19: /**
20: * @internal
21: *
22: * Read only fields
23: *
24: * @var string[]
25: */
26: private static $READ_ONLY_FIELDS = array('category', 'type', 'status', 'country', 'reasons', 'createdOn', 'uploadFiles');
27:
28: /**
29: * Creates a instance of HyperwalletVerificationDocument
30: *
31: * @param string[] $properties The default properties
32: */
33: public function __construct(array $properties = array()) {
34: parent::__construct(self::$READ_ONLY_FIELDS, $properties);
35: }
36:
37: /**
38: * Get the HyperwalletVerificationDocument creation date
39: *
40: * @return \DateTime
41: */
42: public function getCreatedOn() {
43: return $this->createdOn ? new \DateTime($this->createdOn) : null;
44: }
45:
46: /**
47: * Get the document status
48: *
49: * @return string
50: */
51: public function getStatus() {
52: return $this->status;
53: }
54:
55: /**
56: * Get the document category
57: *
58: * @return string
59: */
60: public function getCategory() {
61: return $this->category;
62: }
63:
64: // /**
65: // * Set the document category
66: // *
67: // * @param string $category
68: // * @return HyperwalletVerificationDocument
69: // */
70: // public function setCategory($category) {
71: // $this->category = $category;
72: // return $this;
73: // }
74:
75: /**
76: * Get the document type
77: *
78: * @return string
79: */
80: public function getType() {
81: return $this->type;
82: }
83:
84: // /**
85: // * Set the document type
86: // *
87: // * @param string $type
88: // * @return HyperwalletVerificationDocument
89: // */
90: // public function setType($type) {
91: // $this->type = $type;
92: // return $this;
93: // }
94:
95: /**
96: * Get the country
97: *
98: * @return string
99: */
100: public function getCountry() {
101: return $this->country;
102: }
103:
104: // /**
105: // * Set the country
106: // *
107: // * @param string $country
108: // * @return HyperwalletVerificationDocument
109: // */
110: // public function setCountry($country) {
111: // $this->country = $country;
112: // return $this;
113: // }
114:
115: /**
116: * Get the document reasons
117: *
118: * @return HyperwalletVerificationDocumentReason $reasons
119: */
120: public function getReasons($reasons) {
121: return $this->reasons;
122: }
123:
124: // /**
125: // * Set the document reasons
126: // *
127: // * @param HyperwalletVerificationDocumentReason $reasons
128: // * @return HyperwalletVerificationDocument
129: // */
130: // public function setReasons($reasons) {
131: // $this->reasons = $reasons;
132: // return $this;
133: // }
134:
135: /**
136: * Get the uploadFiles
137: *
138: * @return object $uploadFiles
139: */
140: public function getUploadFiles($uploadFiles) {
141: return $this->uploadFiles;
142: }
143:
144: // /**
145: // * Set the uploadFiles
146: // *
147: // * @param object $uploadFiles
148: // * @return HyperwalletVerificationDocument
149: // */
150: // public function setUploadFiles($uploadFiles) {
151: // $this->uploadFiles = $uploadFiles;
152: // return $this;
153: // }
154: }
155:
156: /**
157: * Represents a V4 HyperwalletVerificationDocumentCollection
158: *
159: * @property array $documents The list of documents
160: *
161: * @package Hyperwallet\Model
162: */
163: class HyperwalletVerificationDocumentCollection {
164:
165: public function __construct(HyperwalletVerificationDocument ...$documents) {
166: $this->documents = $documents;
167: }
168:
169: public function getDocuments() {
170: return $this->documents;
171: }
172:
173: public function getIterator() {
174: return new \ArrayIterator($this->documents);
175: }
176:
177: }
178: