summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBernhard Posselt <dev@bernhard-posselt.com>2014-12-16 19:50:31 +0100
committerBernhard Posselt <dev@bernhard-posselt.com>2014-12-16 19:50:31 +0100
commitd59c4e832fea87d03d199a3211186a47fd252c32 (patch)
tree1ef7534a027e296a1b3da23e9a1f7e4efa9448c4
parent5b9c453071fe900529cd26b88fbc681d8b153b43 (diff)
downloadnextcloud-server-d59c4e832fea87d03d199a3211186a47fd252c32.tar.gz
nextcloud-server-d59c4e832fea87d03d199a3211186a47fd252c32.zip
first round of deprecation
-rw-r--r--lib/private/appframework/core/api.php11
-rw-r--r--lib/private/appframework/dependencyinjection/dicontainer.php4
-rw-r--r--lib/public/appframework/iapi.php9
-rw-r--r--lib/public/appframework/iappcontainer.php4
4 files changed, 28 insertions, 0 deletions
diff --git a/lib/private/appframework/core/api.php b/lib/private/appframework/core/api.php
index f68c677d106..2f01015bb15 100644
--- a/lib/private/appframework/core/api.php
+++ b/lib/private/appframework/core/api.php
@@ -32,6 +32,7 @@ use OCP\AppFramework\IApi;
*
* Should you find yourself in need for more methods, simply inherit from this
* class and add your methods
+ * @deprecated
*/
class API implements IApi{
@@ -58,6 +59,7 @@ class API implements IApi{
/**
* Adds a new javascript file
+ * @deprecated include javascript and css in template files
* @param string $scriptName the name of the javascript in js/ without the suffix
* @param string $appName the name of the app, defaults to the current one
*/
@@ -71,6 +73,7 @@ class API implements IApi{
/**
* Adds a new css file
+ * @deprecated include javascript and css in template files
* @param string $styleName the name of the css file in css/without the suffix
* @param string $appName the name of the app, defaults to the current one
*/
@@ -83,6 +86,7 @@ class API implements IApi{
/**
+ * @deprecated include javascript and css in template files
* shorthand for addScript for files in the 3rdparty directory
* @param string $name the name of the file without the suffix
*/
@@ -92,6 +96,7 @@ class API implements IApi{
/**
+ * @deprecated include javascript and css in template files
* shorthand for addStyle for files in the 3rdparty directory
* @param string $name the name of the file without the suffix
*/
@@ -101,7 +106,10 @@ class API implements IApi{
/**
+ * @deprecated communication between apps should happen over built in
+ * callbacks or interfaces (check the contacts and calendar managers)
* Checks if an app is enabled
+ * also use \OC::$server->getAppManager()->isEnabledForUser($appName)
* @param string $appName the name of an app
* @return bool true if app is enabled
*/
@@ -120,6 +128,7 @@ class API implements IApi{
}
/**
+ * @deprecated register hooks directly for class that build in hook interfaces
* connects a function to a hook
* @param string $signalClass class name of emitter
* @param string $signalName name of signal
@@ -134,6 +143,7 @@ class API implements IApi{
}
/**
+ * @deprecated implement the emitter interface instead
* Emits a signal. To get data from the slot use references!
* @param string $signalClass class name of emitter
* @param string $signalName name of signal
@@ -146,6 +156,7 @@ class API implements IApi{
/**
* clear hooks
+ * @deprecated clear hooks directly for class that build in hook interfaces
* @param string $signalClass
* @param string $signalName
*/
diff --git a/lib/private/appframework/dependencyinjection/dicontainer.php b/lib/private/appframework/dependencyinjection/dicontainer.php
index 98525ed3202..517ada2d205 100644
--- a/lib/private/appframework/dependencyinjection/dicontainer.php
+++ b/lib/private/appframework/dependencyinjection/dicontainer.php
@@ -155,6 +155,7 @@ class DIContainer extends SimpleContainer implements IAppContainer{
/**
+ * @deprecated implements only deprecated methods
* @return IApi
*/
function getCoreApi()
@@ -194,6 +195,8 @@ class DIContainer extends SimpleContainer implements IAppContainer{
}
/**
+ * @deprecated use the groupmanager instead to find out if the user is in
+ * the admin group
* @return boolean
*/
function isAdminUser() {
@@ -206,6 +209,7 @@ class DIContainer extends SimpleContainer implements IAppContainer{
}
/**
+ * @deprecated use the ILogger instead
* @param string $message
* @param string $level
* @return mixed
diff --git a/lib/public/appframework/iapi.php b/lib/public/appframework/iapi.php
index ecbc0fd1900..96199d90b92 100644
--- a/lib/public/appframework/iapi.php
+++ b/lib/public/appframework/iapi.php
@@ -30,6 +30,7 @@ namespace OCP\AppFramework;
/**
* A few very basic and frequently used API functions are combined in here
+ * @deprecated
*/
interface IApi {
@@ -44,6 +45,7 @@ interface IApi {
/**
* Adds a new javascript file
+ * @deprecated include javascript and css in template files
* @param string $scriptName the name of the javascript in js/ without the suffix
* @param string $appName the name of the app, defaults to the current one
* @return void
@@ -53,6 +55,7 @@ interface IApi {
/**
* Adds a new css file
+ * @deprecated include javascript and css in template files
* @param string $styleName the name of the css file in css/without the suffix
* @param string $appName the name of the app, defaults to the current one
* @return void
@@ -61,6 +64,7 @@ interface IApi {
/**
+ * @deprecated include javascript and css in template files
* shorthand for addScript for files in the 3rdparty directory
* @param string $name the name of the file without the suffix
* @return void
@@ -69,6 +73,7 @@ interface IApi {
/**
+ * @deprecated include javascript and css in template files
* shorthand for addStyle for files in the 3rdparty directory
* @param string $name the name of the file without the suffix
* @return void
@@ -78,6 +83,10 @@ interface IApi {
/**
* Checks if an app is enabled
+ * @deprecated communication between apps should happen over built in
+ * callbacks or interfaces (check the contacts and calendar managers)
+ * Checks if an app is enabled
+ * also use \OC::$server->getAppManager()->isEnabledForUser($appName)
* @param string $appName the name of an app
* @return bool true if app is enabled
*/
diff --git a/lib/public/appframework/iappcontainer.php b/lib/public/appframework/iappcontainer.php
index a0b0c06881a..3621d69a542 100644
--- a/lib/public/appframework/iappcontainer.php
+++ b/lib/public/appframework/iappcontainer.php
@@ -40,6 +40,7 @@ interface IAppContainer extends IContainer{
function getAppName();
/**
+ * @deprecated implements only deprecated methods
* @return IApi
*/
function getCoreApi();
@@ -62,10 +63,13 @@ interface IAppContainer extends IContainer{
/**
* @return boolean
+ * @deprecated use the groupmanager instead to find out if the user is in
+ * the admin group
*/
function isAdminUser();
/**
+ * @deprecated use the ILogger instead
* @param string $message
* @param string $level
* @return mixed