From 3dc598bc7c2604e24b9e0be1189d9d78b43737ea Mon Sep 17 00:00:00 2001 From: wei <> Date: Wed, 17 Jan 2007 08:01:40 +0000 Subject: Add active record generator. --- framework/3rdParty/PhpShell/PHP/Shell/Commands.php | 10 +++++----- .../PhpShell/PHP/Shell/Extensions/VerbosePrint.php | 6 +++--- framework/3rdParty/PhpShell/PHP/Shell/Options.php | 18 +++++++++--------- 3 files changed, 17 insertions(+), 17 deletions(-) (limited to 'framework/3rdParty/PhpShell/PHP/Shell') diff --git a/framework/3rdParty/PhpShell/PHP/Shell/Commands.php b/framework/3rdParty/PhpShell/PHP/Shell/Commands.php index 5a5e7e9b..3d4bf5b2 100644 --- a/framework/3rdParty/PhpShell/PHP/Shell/Commands.php +++ b/framework/3rdParty/PhpShell/PHP/Shell/Commands.php @@ -3,14 +3,14 @@ /** * Commands for the PHP_Shell * -* Extensions can register their own commands for the shell like the +* Extensions can register their own commands for the shell like the * InlineHelp Extension which provides inline help for all functions * -* It uses the pattern '? ' to catch the cmdline strings. +* It uses the pattern '? ' to catch the cmdline strings. * -* registerCommand() should be called by the extensions in the register() +* registerCommand() should be called by the extensions in the register() * method. Its parameters are -* - the regex which matches the command +* - the regex which matches the command * - the object and the method to call if the command is matched * - the human readable command string and the description for the help */ @@ -23,7 +23,7 @@ class PHP_Shell_Commands { static protected $instance; /** - * registered commands + * registered commands * * array('quit' => ... ) * diff --git a/framework/3rdParty/PhpShell/PHP/Shell/Extensions/VerbosePrint.php b/framework/3rdParty/PhpShell/PHP/Shell/Extensions/VerbosePrint.php index 843292b0..425937c1 100644 --- a/framework/3rdParty/PhpShell/PHP/Shell/Extensions/VerbosePrint.php +++ b/framework/3rdParty/PhpShell/PHP/Shell/Extensions/VerbosePrint.php @@ -4,12 +4,12 @@ class PHP_Shell_Extensions_VerbosePrint implements PHP_Shell_Extension { protected $oneshot_verbose = false; public function register() { - $cmd = PHP_Shell_Commands::getInstance(); +/* $cmd = PHP_Shell_Commands::getInstance(); $cmd->registerCommand('#^p #', $this, 'cmdPrint', 'p ', 'print the variable verbosly'); $opt = PHP_Shell_Options::getInstance(); $opt->registerOption('verboseprint', $this, 'optSetVerbose'); - +*/ } /** @@ -48,7 +48,7 @@ class PHP_Shell_Extensions_VerbosePrint implements PHP_Shell_Extension { $v = $this->opt_verbose || $this->oneshot_verbose; $this->oneshot_verbose = false; - + return $v; } } diff --git a/framework/3rdParty/PhpShell/PHP/Shell/Options.php b/framework/3rdParty/PhpShell/PHP/Shell/Options.php index 649d6727..8f5e57d1 100644 --- a/framework/3rdParty/PhpShell/PHP/Shell/Options.php +++ b/framework/3rdParty/PhpShell/PHP/Shell/Options.php @@ -1,7 +1,7 @@ registerCommand('#^:set #', $this, 'cmdSet', ':set ', 'set a shell variable'); +// $cmd = PHP_Shell_Commands::getInstance(); + // $cmd->registerCommand('#^:set #', $this, 'cmdSet', ':set ', 'set a shell variable'); } /** @@ -41,7 +41,7 @@ class PHP_Shell_Options implements PHP_Shell_Extension { * @param object a object handle * @param string method-name of the setor in the object * @param string (unused) - */ + */ public function registerOption($option, $obj, $setor, $getor = null) { if (!method_exists($obj, $setor)) { throw new Exception(sprintf("setor %s doesn't exist on class %s", $setor, get_class($obj))); @@ -88,15 +88,15 @@ class PHP_Shell_Options implements PHP_Shell_Extension { } $this->option_aliases[trim($alias)] = trim($option); - + } /** * execute a :set command * * calls the setor for the :set