summaryrefslogtreecommitdiff
path: root/app/Api
diff options
context:
space:
mode:
authorFrederic Guillot <fred@kanboard.net>2016-05-16 21:07:29 -0400
committerFrederic Guillot <fred@kanboard.net>2016-05-16 21:07:29 -0400
commitb1e2ca00ce7375ffcbe5e927135c8892036e6bd6 (patch)
tree07ce453261f6493de7c901cfd8b4f0d9af85556d /app/Api
parent4514bc1d4b4abff23902e46da76e70f13a3647eb (diff)
Rename Api classes
Diffstat (limited to 'app/Api')
-rw-r--r--app/Api/ActionApi.php (renamed from app/Api/Action.php)6
-rw-r--r--app/Api/AppApi.php (renamed from app/Api/App.php)6
-rw-r--r--app/Api/AuthApi.php (renamed from app/Api/Auth.php)5
-rw-r--r--app/Api/BaseApi.php (renamed from app/Api/Base.php)5
-rw-r--r--app/Api/BoardApi.php (renamed from app/Api/Board.php)4
-rw-r--r--app/Api/CategoryApi.php (renamed from app/Api/Category.php)6
-rw-r--r--app/Api/ColumnApi.php (renamed from app/Api/Column.php)4
-rw-r--r--app/Api/CommentApi.php (renamed from app/Api/Comment.php)6
-rw-r--r--app/Api/FileApi.php (renamed from app/Api/File.php)7
-rw-r--r--app/Api/GroupApi.php (renamed from app/Api/Group.php)6
-rw-r--r--app/Api/GroupMemberApi.php (renamed from app/Api/GroupMember.php)6
-rw-r--r--app/Api/LinkApi.php (renamed from app/Api/Link.php)6
-rw-r--r--app/Api/MeApi.php (renamed from app/Api/Me.php)4
-rw-r--r--app/Api/ProjectApi.php (renamed from app/Api/Project.php)4
-rw-r--r--app/Api/ProjectPermissionApi.php (renamed from app/Api/ProjectPermission.php)5
-rw-r--r--app/Api/SubtaskApi.php (renamed from app/Api/Subtask.php)6
-rw-r--r--app/Api/SwimlaneApi.php (renamed from app/Api/Swimlane.php)6
-rw-r--r--app/Api/TaskApi.php (renamed from app/Api/Task.php)4
-rw-r--r--app/Api/TaskLinkApi.php (renamed from app/Api/TaskLink.php)6
-rw-r--r--app/Api/UserApi.php (renamed from app/Api/User.php)5
20 files changed, 66 insertions, 41 deletions
diff --git a/app/Api/Action.php b/app/Api/ActionApi.php
index 9e3b86f6..0647f9e8 100644
--- a/app/Api/Action.php
+++ b/app/Api/ActionApi.php
@@ -2,13 +2,15 @@
namespace Kanboard\Api;
+use Kanboard\Core\Base;
+
/**
* Action API controller
*
- * @package api
+ * @package Kanboard\Api
* @author Frederic Guillot
*/
-class Action extends \Kanboard\Core\Base
+class ActionApi extends Base
{
public function getAvailableActions()
{
diff --git a/app/Api/App.php b/app/Api/AppApi.php
index 1c4737c0..865ba21a 100644
--- a/app/Api/App.php
+++ b/app/Api/AppApi.php
@@ -2,13 +2,15 @@
namespace Kanboard\Api;
+use Kanboard\Core\Base;
+
/**
* App API controller
*
- * @package api
+ * @package Kanboard\Api
* @author Frederic Guillot
*/
-class App extends \Kanboard\Core\Base
+class AppApi extends Base
{
public function getTimezone()
{
diff --git a/app/Api/Auth.php b/app/Api/AuthApi.php
index 1cc6627f..a9ad5baf 100644
--- a/app/Api/Auth.php
+++ b/app/Api/AuthApi.php
@@ -7,10 +7,10 @@ use JsonRPC\Exception\AuthenticationFailureException;
/**
* Base class
*
- * @package api
+ * @package Kanboard\Api
* @author Frederic Guillot
*/
-class Auth extends Base
+class AuthApi extends BaseApi
{
/**
* Check api credentials
@@ -20,6 +20,7 @@ class Auth extends Base
* @param string $password
* @param string $class
* @param string $method
+ * @throws AuthenticationFailureException
*/
public function checkCredentials($username, $password, $class, $method)
{
diff --git a/app/Api/Base.php b/app/Api/BaseApi.php
index ea817f7d..37e11030 100644
--- a/app/Api/Base.php
+++ b/app/Api/BaseApi.php
@@ -3,14 +3,15 @@
namespace Kanboard\Api;
use JsonRPC\Exception\AccessDeniedException;
+use Kanboard\Core\Base;
/**
* Base class
*
- * @package api
+ * @package Kanboard\Api
* @author Frederic Guillot
*/
-abstract class Base extends \Kanboard\Core\Base
+abstract class BaseApi extends Base
{
private $user_allowed_procedures = array(
'getMe',
diff --git a/app/Api/Board.php b/app/Api/BoardApi.php
index 185ac51a..c7d93aa0 100644
--- a/app/Api/Board.php
+++ b/app/Api/BoardApi.php
@@ -5,10 +5,10 @@ namespace Kanboard\Api;
/**
* Board API controller
*
- * @package api
+ * @package Kanboard\Api
* @author Frederic Guillot
*/
-class Board extends Base
+class BoardApi extends BaseApi
{
public function getBoard($project_id)
{
diff --git a/app/Api/Category.php b/app/Api/CategoryApi.php
index fbd61c56..7c5d3bfb 100644
--- a/app/Api/Category.php
+++ b/app/Api/CategoryApi.php
@@ -2,13 +2,15 @@
namespace Kanboard\Api;
+use Kanboard\Core\Base;
+
/**
* Category API controller
*
- * @package api
+ * @package Kanboard\Api
* @author Frederic Guillot
*/
-class Category extends \Kanboard\Core\Base
+class CategoryApi extends Base
{
public function getCategory($category_id)
{
diff --git a/app/Api/Column.php b/app/Api/ColumnApi.php
index ddc3a5d0..45ce521d 100644
--- a/app/Api/Column.php
+++ b/app/Api/ColumnApi.php
@@ -5,10 +5,10 @@ namespace Kanboard\Api;
/**
* Column API controller
*
- * @package api
+ * @package Kanboard\Api
* @author Frederic Guillot
*/
-class Column extends Base
+class ColumnApi extends BaseApi
{
public function getColumns($project_id)
{
diff --git a/app/Api/Comment.php b/app/Api/CommentApi.php
index 1fc1c708..f16b0f7f 100644
--- a/app/Api/Comment.php
+++ b/app/Api/CommentApi.php
@@ -2,13 +2,15 @@
namespace Kanboard\Api;
+use Kanboard\Core\Base;
+
/**
* Comment API controller
*
- * @package api
+ * @package Kanboard\Api
* @author Frederic Guillot
*/
-class Comment extends \Kanboard\Core\Base
+class CommentApi extends Base
{
public function getComment($comment_id)
{
diff --git a/app/Api/File.php b/app/Api/FileApi.php
index 71c31c76..cc2e3986 100644
--- a/app/Api/File.php
+++ b/app/Api/FileApi.php
@@ -7,10 +7,10 @@ use Kanboard\Core\ObjectStorage\ObjectStorageException;
/**
* File API controller
*
- * @package api
+ * @package Kanboard\Api
* @author Frederic Guillot
*/
-class File extends Base
+class FileApi extends BaseApi
{
public function getTaskFile($file_id)
{
@@ -32,8 +32,9 @@ class File extends Base
}
} catch (ObjectStorageException $e) {
$this->logger->error($e->getMessage());
- return '';
}
+
+ return '';
}
public function createTaskFile($project_id, $task_id, $filename, $blob)
diff --git a/app/Api/Group.php b/app/Api/GroupApi.php
index a1e0a73d..f1841fa3 100644
--- a/app/Api/Group.php
+++ b/app/Api/GroupApi.php
@@ -2,13 +2,15 @@
namespace Kanboard\Api;
+use Kanboard\Core\Base;
+
/**
* Group API controller
*
- * @package api
+ * @package Kanboard\Api
* @author Frederic Guillot
*/
-class Group extends \Kanboard\Core\Base
+class GroupApi extends Base
{
public function createGroup($name, $external_id = '')
{
diff --git a/app/Api/GroupMember.php b/app/Api/GroupMemberApi.php
index 9d2a4796..f5171e23 100644
--- a/app/Api/GroupMember.php
+++ b/app/Api/GroupMemberApi.php
@@ -2,13 +2,15 @@
namespace Kanboard\Api;
+use Kanboard\Core\Base;
+
/**
* Group Member API controller
*
- * @package api
+ * @package Kanboard\Api
* @author Frederic Guillot
*/
-class GroupMember extends \Kanboard\Core\Base
+class GroupMemberApi extends Base
{
public function getMemberGroups($user_id)
{
diff --git a/app/Api/Link.php b/app/Api/LinkApi.php
index 23a9916d..a76cb802 100644
--- a/app/Api/Link.php
+++ b/app/Api/LinkApi.php
@@ -2,13 +2,15 @@
namespace Kanboard\Api;
+use Kanboard\Core\Base;
+
/**
* Link API controller
*
- * @package api
+ * @package Kanboard\Api
* @author Frederic Guillot
*/
-class Link extends \Kanboard\Core\Base
+class LinkApi extends Base
{
/**
* Get a link by id
diff --git a/app/Api/Me.php b/app/Api/MeApi.php
index 3d08626a..7d46a962 100644
--- a/app/Api/Me.php
+++ b/app/Api/MeApi.php
@@ -7,10 +7,10 @@ use Kanboard\Model\Subtask as SubtaskModel;
/**
* Me API controller
*
- * @package api
+ * @package Kanboard\Api
* @author Frederic Guillot
*/
-class Me extends Base
+class MeApi extends BaseApi
{
public function getMe()
{
diff --git a/app/Api/Project.php b/app/Api/ProjectApi.php
index 846d7046..70cd8d16 100644
--- a/app/Api/Project.php
+++ b/app/Api/ProjectApi.php
@@ -5,10 +5,10 @@ namespace Kanboard\Api;
/**
* Project API controller
*
- * @package api
+ * @package Kanboard\Api
* @author Frederic Guillot
*/
-class Project extends Base
+class ProjectApi extends BaseApi
{
public function getProjectById($project_id)
{
diff --git a/app/Api/ProjectPermission.php b/app/Api/ProjectPermissionApi.php
index 11e92af0..10ee3852 100644
--- a/app/Api/ProjectPermission.php
+++ b/app/Api/ProjectPermissionApi.php
@@ -2,15 +2,16 @@
namespace Kanboard\Api;
+use Kanboard\Core\Base;
use Kanboard\Core\Security\Role;
/**
* Project Permission API controller
*
- * @package api
+ * @package Kanboard\Api
* @author Frederic Guillot
*/
-class ProjectPermission extends \Kanboard\Core\Base
+class ProjectPermissionApi extends Base
{
public function getProjectUsers($project_id)
{
diff --git a/app/Api/Subtask.php b/app/Api/SubtaskApi.php
index 782fdb02..305f9ae7 100644
--- a/app/Api/Subtask.php
+++ b/app/Api/SubtaskApi.php
@@ -2,13 +2,15 @@
namespace Kanboard\Api;
+use Kanboard\Core\Base;
+
/**
* Subtask API controller
*
- * @package api
+ * @package Kanboard\Api
* @author Frederic Guillot
*/
-class Subtask extends \Kanboard\Core\Base
+class SubtaskApi extends Base
{
public function getSubtask($subtask_id)
{
diff --git a/app/Api/Swimlane.php b/app/Api/SwimlaneApi.php
index 03a2819f..f179e11b 100644
--- a/app/Api/Swimlane.php
+++ b/app/Api/SwimlaneApi.php
@@ -2,13 +2,15 @@
namespace Kanboard\Api;
+use Kanboard\Core\Base;
+
/**
* Swimlane API controller
*
- * @package api
+ * @package Kanboard\Api
* @author Frederic Guillot
*/
-class Swimlane extends \Kanboard\Core\Base
+class SwimlaneApi extends Base
{
public function getActiveSwimlanes($project_id)
{
diff --git a/app/Api/Task.php b/app/Api/TaskApi.php
index 1d1211f2..4d745fa6 100644
--- a/app/Api/Task.php
+++ b/app/Api/TaskApi.php
@@ -8,10 +8,10 @@ use Kanboard\Model\Task as TaskModel;
/**
* Task API controller
*
- * @package api
+ * @package Kanboard\Api
* @author Frederic Guillot
*/
-class Task extends Base
+class TaskApi extends BaseApi
{
public function searchTasks($project_id, $query)
{
diff --git a/app/Api/TaskLink.php b/app/Api/TaskLinkApi.php
index 47d70d1e..8c02c524 100644
--- a/app/Api/TaskLink.php
+++ b/app/Api/TaskLinkApi.php
@@ -2,13 +2,15 @@
namespace Kanboard\Api;
+use Kanboard\Core\Base;
+
/**
* TaskLink API controller
*
- * @package api
+ * @package Kanboard\Api
* @author Frederic Guillot
*/
-class TaskLink extends \Kanboard\Core\Base
+class TaskLinkApi extends Base
{
/**
* Get a task link
diff --git a/app/Api/User.php b/app/Api/UserApi.php
index 6ee935a3..9786e6cf 100644
--- a/app/Api/User.php
+++ b/app/Api/UserApi.php
@@ -2,6 +2,7 @@
namespace Kanboard\Api;
+use Kanboard\Core\Base;
use LogicException;
use Kanboard\Core\Security\Role;
use Kanboard\Core\Ldap\Client as LdapClient;
@@ -11,10 +12,10 @@ use Kanboard\Core\Ldap\User as LdapUser;
/**
* User API controller
*
- * @package api
+ * @package Kanboard\Api
* @author Frederic Guillot
*/
-class User extends \Kanboard\Core\Base
+class UserApi extends Base
{
public function getUser($user_id)
{