@@ 77-84 (lines=8) @@ | ||
74 | * @throws \Exception When boxid is not present |
|
75 | * @return object Result of the request |
|
76 | */ |
|
77 | public function Update($box) |
|
78 | { |
|
79 | if (!isset($box['boxid'])) { |
|
80 | throw new \Exception("box must contain a boxid"); |
|
81 | } |
|
82 | ||
83 | return $this->request(self::HTTP_PUT, "/".$box['boxid'], $box); |
|
84 | } |
|
85 | ||
86 | /** |
|
87 | * Update a box |
|
@@ 93-100 (lines=8) @@ | ||
90 | * @throws \Exception When versionid is not present |
|
91 | * @return object Result of the request |
|
92 | */ |
|
93 | public function UpdateVersion($boxid, $version) |
|
94 | { |
|
95 | if (!isset($version['versionid'])) { |
|
96 | throw new \Exception("version must contain a versionid"); |
|
97 | } |
|
98 | ||
99 | return $this->request(self::HTTP_PUT, "/".$boxid."/version/".$version['versionid'], $version); |
|
100 | } |
|
101 | } |
|
102 |