From 73fd6112622c1c038c5b2a80b2dc011bcc49fe55 Mon Sep 17 00:00:00 2001
From: Michael Oehlhof <typo3@oehlhof.de>
Date: Wed, 20 Jan 2016 21:35:22 +0100
Subject: [PATCH] [TASK] Deprecate some functions not in use anymore in the
 core

Resolves: #72851
Releases: master
Change-Id: I585344f02c92466454e7bb0986a7fd380e4ed303
Reviewed-on: https://review.typo3.org/46118
Reviewed-by: Wouter Wolters <typo3@wouterwolters.nl>
Tested-by: Wouter Wolters <typo3@wouterwolters.nl>
Reviewed-by: Georg Ringer <georg.ringer@gmail.com>
Tested-by: Georg Ringer <georg.ringer@gmail.com>
---
 .../Classes/Utility/BackendUtility.php        |  8 ++++++
 ...eSomeFunctionsNotInUseAnymoreInTheCore.rst | 26 +++++++++++++++++++
 .../ContentObject/ContentObjectRenderer.php   |  2 ++
 3 files changed, 36 insertions(+)
 create mode 100644 typo3/sysext/core/Documentation/Changelog/master/Deprecation-72851-DeprecateSomeFunctionsNotInUseAnymoreInTheCore.rst

diff --git a/typo3/sysext/backend/Classes/Utility/BackendUtility.php b/typo3/sysext/backend/Classes/Utility/BackendUtility.php
index 507691df518b..4a4cd169c12a 100755
--- a/typo3/sysext/backend/Classes/Utility/BackendUtility.php
+++ b/typo3/sysext/backend/Classes/Utility/BackendUtility.php
@@ -231,9 +231,11 @@ class BackendUtility
      * @param string $tablename Table name from which ids is returned
      * @param string $default_tablename $default_tablename denotes what table the number '45' is from (if nothing is prepended on the value)
      * @return string List of ids
+     * @deprecated since TYPO3 CMS 8, will be removed in TYPO3 CMS 9.
      */
     public static function getSQLselectableList($in_list, $tablename, $default_tablename)
     {
+        GeneralUtility::logDeprecatedFunction();
         $list = array();
         if ((string)trim($in_list) != '') {
             $tempItemArray = explode(',', trim($in_list));
@@ -1347,9 +1349,11 @@ class BackendUtility
      *
      * @param string $content Value for 'alt' and 'title' attributes (will be htmlspecialchars()'ed before output)
      * @return string
+     * @deprecated since TYPO3 CMS 8, will be removed in TYPO3 CMS 9.
      */
     public static function titleAltAttrib($content)
     {
+        GeneralUtility::logDeprecatedFunction();
         $out = '';
         $out .= ' alt="' . htmlspecialchars($content) . '"';
         $out .= ' title="' . htmlspecialchars($content) . '"';
@@ -2362,9 +2366,11 @@ class BackendUtility
      * @param array $defaults Defaults
      * @param string $dataPrefix Prefix for formfields
      * @return string HTML for a form.
+     * @deprecated since TYPO3 CMS 8, will be removed in TYPO3 CMS 9.
      */
     public static function makeConfigForm($configArray, $defaults, $dataPrefix)
     {
+        GeneralUtility::logDeprecatedFunction();
         $params = $defaults;
         $lines = array();
         if (is_array($configArray)) {
@@ -4167,9 +4173,11 @@ class BackendUtility
      *
      * @param string $params String of parameters on multiple lines to parse into key-value pairs (see function description)
      * @return array
+     * @deprecated since TYPO3 CMS 8, will be removed in TYPO3 CMS 9.
      */
     public static function processParams($params)
     {
+        GeneralUtility::logDeprecatedFunction();
         $paramArr = array();
         $lines = explode(LF, $params);
         foreach ($lines as $val) {
diff --git a/typo3/sysext/core/Documentation/Changelog/master/Deprecation-72851-DeprecateSomeFunctionsNotInUseAnymoreInTheCore.rst b/typo3/sysext/core/Documentation/Changelog/master/Deprecation-72851-DeprecateSomeFunctionsNotInUseAnymoreInTheCore.rst
new file mode 100644
index 000000000000..315d143a1599
--- /dev/null
+++ b/typo3/sysext/core/Documentation/Changelog/master/Deprecation-72851-DeprecateSomeFunctionsNotInUseAnymoreInTheCore.rst
@@ -0,0 +1,26 @@
+=============================================================================
+Deprecation: #72851 - Deprecate some functions not in use anymore in the core
+=============================================================================
+
+Description
+===========
+
+Deprecate some unused methods:
+
+``BackendUtility::processParams()``
+``BackendUtility::makeConfigForm()``
+``BackendUtility::titleAltAttrib()``
+``BackendUtility::getSQLselectableList()``
+``ContentObjectRenderer->processParams()``
+
+
+Impact
+======
+
+Calling one of the aforementioned methods will write an entry in the deprecation log.
+
+
+Affected Installations
+======================
+
+Instances with custom backend modules that use one of the aforementioned methods.
\ No newline at end of file
diff --git a/typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php b/typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php
index ef2b26ed60ab..98bdea5ce37a 100644
--- a/typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php
+++ b/typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php
@@ -6723,9 +6723,11 @@ class ContentObjectRenderer
      *
      * @param string $params Text which the parameters
      * @return array array with the parameters as key/value pairs
+     * @deprecated since TYPO3 CMS 8, will be removed in TYPO3 CMS 9.
      */
     public function processParams($params)
     {
+        GeneralUtility::logDeprecatedFunction();
         $paramArr = array();
         $lines = GeneralUtility::trimExplode(LF, $params, true);
         foreach ($lines as $val) {
-- 
GitLab