aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Wallabag/ApiBundle/Controller
diff options
context:
space:
mode:
authorNicolas LÅ“uillet <nicolas@loeuillet.org>2015-01-29 16:56:58 +0100
committerNicolas LÅ“uillet <nicolas@loeuillet.org>2015-01-29 16:56:58 +0100
commitf8bf8952541b51481a7463c6efc0b2bc9c1edff1 (patch)
treecb632798f4c6f763ba7c827dcaa885eec4255094 /src/Wallabag/ApiBundle/Controller
parent589dce52c63219d917498d2fdf18e5d7ebe5bf92 (diff)
downloadwallabag-f8bf8952541b51481a7463c6efc0b2bc9c1edff1.tar.gz
wallabag-f8bf8952541b51481a7463c6efc0b2bc9c1edff1.tar.zst
wallabag-f8bf8952541b51481a7463c6efc0b2bc9c1edff1.zip
routing for API, trying to respect #414
Diffstat (limited to 'src/Wallabag/ApiBundle/Controller')
-rw-r--r--src/Wallabag/ApiBundle/Controller/EntryController.php63
1 files changed, 0 insertions, 63 deletions
diff --git a/src/Wallabag/ApiBundle/Controller/EntryController.php b/src/Wallabag/ApiBundle/Controller/EntryController.php
deleted file mode 100644
index 9bf84501..00000000
--- a/src/Wallabag/ApiBundle/Controller/EntryController.php
+++ /dev/null
@@ -1,63 +0,0 @@
1<?php
2
3namespace Wallabag\ApiBundle\Controller;
4
5use Nelmio\ApiDocBundle\Annotation\ApiDoc;
6use Symfony\Bundle\FrameworkBundle\Controller\Controller;
7use Wallabag\CoreBundle\Entity\Entries;
8use FOS\RestBundle\Controller\Annotations\Get;
9use FOS\RestBundle\Controller\Annotations\Delete;
10use FOS\RestBundle\Controller\Annotations\Patch;
11use Wallabag\CoreBundle\Entity\Users;
12
13class EntryController extends Controller
14{
15 /**
16 * Fetches an entry for a given user
17 *
18 * @Get("/u/{user}/entry/{entry}")
19 * @ApiDoc(
20 * requirements={
21 * {"name"="user", "dataType"="string", "requirement"="\w+", "description"="The user ID"},
22 * {"name"="entry", "dataType"="integer", "requirement"="\w+", "description"="The entry ID"}
23 * }
24 * )
25 * @return Entries
26 */
27 public function getAction(Users $user, Entries $entry)
28 {
29 return $entry;
30 }
31
32 /**
33 * Deletes an entry for a given user
34 *
35 * @Delete("/u/{user}/entry/{entry}")
36 * @ApiDoc(
37 * requirements={
38 * {"name"="user", "dataType"="string", "requirement"="\w+", "description"="The user ID"},
39 * {"name"="entry", "dataType"="integer", "requirement"="\w+", "description"="The entry ID"}
40 * }
41 * )
42 */
43 public function deleteAction(Users $user, Entries $entry)
44 {
45
46 }
47
48 /**
49 * Changes several properties of an entry. I.E tags, archived, starred and deleted status
50 *
51 * @Patch("/u/{user}/entry/{entry}")
52 * @ApiDoc(
53 * requirements={
54 * {"name"="user", "dataType"="string", "requirement"="\w+", "description"="The user ID"},
55 * {"name"="entry", "dataType"="integer", "requirement"="\w+", "description"="The entry ID"}
56 * }
57 * )
58 */
59 public function patchAction(Users $user, Entries $entry)
60 {
61
62 }
63}