diff options
author | Bernhard Posselt <nukeawhale@gmail.com> | 2013-06-22 18:18:55 +0200 |
---|---|---|
committer | Bernhard Posselt <nukeawhale@gmail.com> | 2013-06-22 18:18:55 +0200 |
commit | 4affc4f485d1a69426edad1a2a02deb3dbcf9a5e (patch) | |
tree | 27082f73e83bb75873860b6c5397d6c4258749c2 | |
parent | b11cd6e058d6f9f1bbcba568858d8fea34178e4c (diff) |
add api annotations
-rw-r--r-- | external/feedapi.php | 5 | ||||
-rw-r--r-- | external/folderapi.php | 5 | ||||
-rw-r--r-- | external/itemapi.php | 11 | ||||
-rw-r--r-- | external/newsapi.php | 1 | ||||
-rw-r--r-- | tests/unit/external/FeedAPITest.php | 2 | ||||
-rw-r--r-- | tests/unit/external/FolderAPITest.php | 2 | ||||
-rw-r--r-- | tests/unit/external/ItemAPITest.php | 2 | ||||
-rw-r--r-- | tests/unit/external/NewsAPITest.php | 2 |
8 files changed, 26 insertions, 4 deletions
diff --git a/external/feedapi.php b/external/feedapi.php index f2f02831a..cc9753eb5 100644 --- a/external/feedapi.php +++ b/external/feedapi.php @@ -61,6 +61,7 @@ class FeedAPI extends Controller { * @IsSubAdminExemption * @CSRFExemption * @Ajax + * @API */ public function getAll() { $userId = $this->api->getUserId(); @@ -89,6 +90,7 @@ class FeedAPI extends Controller { * @IsSubAdminExemption * @CSRFExemption * @Ajax + * @API */ public function create() { $userId = $this->api->getUserId(); @@ -125,6 +127,7 @@ class FeedAPI extends Controller { * @IsSubAdminExemption * @CSRFExemption * @Ajax + * @API */ public function delete() { $userId = $this->api->getUserId(); @@ -145,6 +148,7 @@ class FeedAPI extends Controller { * @IsSubAdminExemption * @CSRFExemption * @Ajax + * @API */ public function read() { $userId = $this->api->getUserId(); @@ -161,6 +165,7 @@ class FeedAPI extends Controller { * @IsSubAdminExemption * @CSRFExemption * @Ajax + * @API */ public function move() { $userId = $this->api->getUserId(); diff --git a/external/folderapi.php b/external/folderapi.php index 237f23660..1781f3c83 100644 --- a/external/folderapi.php +++ b/external/folderapi.php @@ -57,6 +57,7 @@ class FolderAPI extends Controller { * @IsSubAdminExemption * @CSRFExemption * @Ajax + * @API */ public function getAll() { $userId = $this->api->getUserId(); @@ -77,6 +78,7 @@ class FolderAPI extends Controller { * @IsSubAdminExemption * @CSRFExemption * @Ajax + * @API */ public function create() { $userId = $this->api->getUserId(); @@ -102,6 +104,7 @@ class FolderAPI extends Controller { * @IsAdminExemption * @IsSubAdminExemption * @CSRFExemption + * @API * @Ajax */ public function delete() { @@ -123,6 +126,7 @@ class FolderAPI extends Controller { * @IsSubAdminExemption * @CSRFExemption * @Ajax + * @API */ public function update() { $userId = $this->api->getUserId(); @@ -149,6 +153,7 @@ class FolderAPI extends Controller { * @IsSubAdminExemption * @CSRFExemption * @Ajax + * @API */ public function read() { $userId = $this->api->getUserId(); diff --git a/external/itemapi.php b/external/itemapi.php index 2d484ce7b..83aa0f4da 100644 --- a/external/itemapi.php +++ b/external/itemapi.php @@ -52,6 +52,7 @@ class ItemAPI extends Controller { * @IsSubAdminExemption * @CSRFExemption * @Ajax + * @API */ public function getAll() { $result = array( @@ -93,6 +94,7 @@ class ItemAPI extends Controller { * @IsSubAdminExemption * @CSRFExemption * @Ajax + * @API */ public function getUpdated() { $result = array( @@ -152,6 +154,7 @@ class ItemAPI extends Controller { * @IsSubAdminExemption * @CSRFExemption * @Ajax + * @API */ public function read() { return $this->setRead(true); @@ -163,6 +166,7 @@ class ItemAPI extends Controller { * @IsSubAdminExemption * @CSRFExemption * @Ajax + * @API */ public function unread() { return $this->setRead(false); @@ -174,6 +178,7 @@ class ItemAPI extends Controller { * @IsSubAdminExemption * @CSRFExemption * @Ajax + * @API */ public function star() { return $this->setStarred(true); @@ -185,6 +190,7 @@ class ItemAPI extends Controller { * @IsSubAdminExemption * @CSRFExemption * @Ajax + * @API */ public function unstar() { return $this->setStarred(false); @@ -196,6 +202,7 @@ class ItemAPI extends Controller { * @IsSubAdminExemption * @CSRFExemption * @Ajax + * @API */ public function readAll() { $userId = $this->api->getUserId(); @@ -227,6 +234,7 @@ class ItemAPI extends Controller { * @IsSubAdminExemption * @CSRFExemption * @Ajax + * @API */ public function readMultiple() { return $this->setMultipleRead(true); @@ -238,6 +246,7 @@ class ItemAPI extends Controller { * @IsSubAdminExemption * @CSRFExemption * @Ajax + * @API */ public function unreadMultiple() { return $this->setMultipleRead(false); @@ -266,6 +275,7 @@ class ItemAPI extends Controller { * @IsSubAdminExemption * @CSRFExemption * @Ajax + * @API */ public function starMultiple() { return $this->setMultipleStarred(true); @@ -277,6 +287,7 @@ class ItemAPI extends Controller { * @IsSubAdminExemption * @CSRFExemption * @Ajax + * @API */ public function unstarMultiple() { return $this->setMultipleStarred(false); diff --git a/external/newsapi.php b/external/newsapi.php index 4a2e16fa3..cb6231b80 100644 --- a/external/newsapi.php +++ b/external/newsapi.php @@ -44,6 +44,7 @@ class NewsAPI extends Controller { * @IsSubAdminExemption * @CSRFExemption * @Ajax + * @API */ public function version() { $version = $this->api->getAppValue('installed_version'); diff --git a/tests/unit/external/FeedAPITest.php b/tests/unit/external/FeedAPITest.php index 9b9d02514..a42a1c8c9 100644 --- a/tests/unit/external/FeedAPITest.php +++ b/tests/unit/external/FeedAPITest.php @@ -85,7 +85,7 @@ class FeedAPITest extends ControllerTestUtility { private function assertDefaultAnnotations($methodName){ $annotations = array('IsAdminExemption', 'IsSubAdminExemption', - 'Ajax', 'CSRFExemption'); + 'Ajax', 'CSRFExemption', 'API'); $this->assertAnnotations($this->feedAPI, $methodName, $annotations); } diff --git a/tests/unit/external/FolderAPITest.php b/tests/unit/external/FolderAPITest.php index 60ab40a81..8aef3d3f1 100644 --- a/tests/unit/external/FolderAPITest.php +++ b/tests/unit/external/FolderAPITest.php @@ -80,7 +80,7 @@ class FolderAPITest extends ControllerTestUtility { private function assertDefaultAnnotations($methodName){ $annotations = array('IsAdminExemption', 'IsSubAdminExemption', - 'Ajax', 'CSRFExemption'); + 'Ajax', 'CSRFExemption', 'API'); $this->assertAnnotations($this->folderAPI, $methodName, $annotations); } diff --git a/tests/unit/external/ItemAPITest.php b/tests/unit/external/ItemAPITest.php index f2533b4fa..ee5f22c2d 100644 --- a/tests/unit/external/ItemAPITest.php +++ b/tests/unit/external/ItemAPITest.php @@ -70,7 +70,7 @@ class ItemAPITest extends ControllerTestUtility { private function assertDefaultAnnotations($methodName){ $annotations = array('IsAdminExemption', 'IsSubAdminExemption', - 'Ajax', 'CSRFExemption'); + 'Ajax', 'CSRFExemption', 'API'); $this->assertAnnotations($this->itemAPI, $methodName, $annotations); } diff --git a/tests/unit/external/NewsAPITest.php b/tests/unit/external/NewsAPITest.php index 3cccd62ff..e1fd2e50a 100644 --- a/tests/unit/external/NewsAPITest.php +++ b/tests/unit/external/NewsAPITest.php @@ -52,7 +52,7 @@ class NewsAPITest extends ControllerTestUtility { private function assertDefaultAnnotations($methodName){ $annotations = array('IsAdminExemption', 'IsSubAdminExemption', - 'Ajax', 'CSRFExemption'); + 'Ajax', 'CSRFExemption', 'API'); $this->assertAnnotations($this->newsAPI, $methodName, $annotations); } |