cvs: pear-core /PEAR/Frontend CLI.php
| From: | Helgi �ormar �orbj�rnsson | Date: | Sat, 12 Jul 2008 19:03:07 +0000 |
| Subject: | cvs: pear-core /PEAR/Frontend CLI.php | ||
| Groups: | php.pear.cvs php.pear.core | ||
| Request: | Send a blank email to pear-core+get-7644@lists.php.net to get a copy of this message | ||
dufuz Sat Jul 12 19:03:07 2008 UTC
Modified files:
/pear-core/PEAR/Frontend CLI.php
Log:
Kill all the deprecated functions, they were deprecated 6 years ago.
http://cvs.php.net/viewvc.cgi/pear-core/PEAR/Frontend/CLI.php?r1=1.69&r2=1.70&diff_format=u
Index: pear-core/PEAR/Frontend/CLI.php
diff -u pear-core/PEAR/Frontend/CLI.php:1.69 pear-core/PEAR/Frontend/CLI.php:1.70
--- pear-core/PEAR/Frontend/CLI.php:1.69 Sat Jul 12 18:59:39 2008
+++ pear-core/PEAR/Frontend/CLI.php Sat Jul 12 19:03:06 2008
@@ -16,7 +16,7 @@
* @author Greg Beaver <cellog@php.net>
* @copyright 1997-2008 The PHP Group
* @license http://www.php.net/license/3_0.txt
PHP License 3.0
- * @version CVS: $Id: CLI.php,v 1.69 2008/07/12 18:59:39 dufuz Exp $
+ * @version CVS: $Id: CLI.php,v 1.70 2008/07/12 19:03:06 dufuz Exp $
* @link http://pear.php.net/package/PEAR
* @since File available since Release 0.1
*/
@@ -39,8 +39,6 @@
*/
class PEAR_Frontend_CLI extends PEAR_Frontend
{
- // {{{ properties
-
/**
* What type of user interface this frontend is for.
* @var string
@@ -51,13 +49,9 @@
var $params = array();
var $term = array(
- 'bold' => '',
+ 'bold' => '',
'normal' => '',
- );
-
- // }}}
-
- // {{{ constructor
+ );
function PEAR_Frontend_CLI()
{
@@ -79,36 +73,16 @@
}
}
- // }}}
-
- // {{{ displayLine(text)
-
- function displayLine($text)
- {
- trigger_error("PEAR_Frontend_CLI::displayLine deprecated", E_USER_ERROR);
- }
-
function _displayLine($text)
{
print "$this->lp$text\n";
}
- // }}}
- // {{{ display(text)
-
- function display($text)
- {
- trigger_error("PEAR_Frontend_CLI::display deprecated", E_USER_ERROR);
- }
-
function _display($text)
{
print $text;
}
- // }}}
- // {{{ displayError(eobj)
-
/**
* @param object PEAR_Error object
*/
@@ -117,9 +91,6 @@
return $this->_displayLine($eobj->getMessage());
}
- // }}}
- // {{{ displayFatalError(eobj)
-
/**
* @param object PEAR_Error object
*/
@@ -163,22 +134,12 @@
exit(1);
}
- // }}}
- // {{{ displayHeading(title)
-
- function displayHeading($title)
- {
- trigger_error("PEAR_Frontend_CLI::displayHeading deprecated", E_USER_ERROR);
- }
-
function _displayHeading($title)
{
print $this->lp.$this->bold($title)."\n";
print $this->lp.str_repeat("=", strlen($title))."\n";
}
- // }}}
-
/**
* Instruct the runInstallScript method to skip a paramgroup that matches the
* id value passed in.
@@ -337,7 +298,6 @@
} while (is_array($answers) && count(array_filter($answers)) != count($prompts));
return $answers;
}
- // {{{ userDialog(prompt, [type], [default])
function userDialog($command, $prompts, $types = array(), $defaults = array(),
$screensize = 20)
@@ -422,9 +382,6 @@
return $result;
}
- // }}}
- // {{{ userConfirm(prompt, [default])
-
function userConfirm($prompt, $default = 'yes')
{
trigger_error("PEAR_Frontend_CLI::userConfirm not yet converted", E_USER_ERROR);
@@ -450,14 +407,6 @@
return false;
}
- // }}}
- // {{{ startTable([params])
-
- function startTable($params = array())
- {
- trigger_error("PEAR_Frontend_CLI::startTable deprecated", E_USER_ERROR);
- }
-
function _startTable($params = array())
{
$params['table_data'] = array();
@@ -467,14 +416,6 @@
$this->params = $params;
}
- // }}}
- // {{{ tableRow(columns, [rowparams], [colparams])
-
- function tableRow($columns, $rowparams = array(), $colparams = array())
- {
- trigger_error("PEAR_Frontend_CLI::tableRow deprecated", E_USER_ERROR);
- }
-
function _tableRow($columns, $rowparams = array(), $colparams = array())
{
$highest = 1;
@@ -527,14 +468,6 @@
$this->params['table_data'][] = $new_row;
}
- // }}}
- // {{{ endTable()
-
- function endTable()
- {
- trigger_error("PEAR_Frontend_CLI::endTable deprecated", E_USER_ERROR);
- }
-
function _endTable()
{
extract($this->params);
@@ -647,9 +580,6 @@
}
}
- // }}}
- // {{{ outputData()
-
function outputData($data, $command = '_default')
{
switch ($command) {
@@ -783,9 +713,6 @@
}
}
- // }}}
- // {{{ log(text)
-
function log($text, $append_crlf = true)
{
if ($append_crlf) {
@@ -794,9 +721,6 @@
return $this->_display($text);
}
- // }}}
- // {{{ bold($text)
-
function bold($text)
{
if (empty($this->term['bold'])) {
@@ -804,5 +728,4 @@
}
return $this->term['bold'] . $text . $this->term['normal'];
}
- // }}}
}
\ No newline at end of file