rw.php

来自「php-4.4.7学习linux时下载的源代码」· PHP 代码 · 共 67 行

PHP
67
字号
<?php/** * <tasks:replace> - read/write version * * PHP versions 4 and 5 * * LICENSE: This source file is subject to version 3.0 of the PHP license * that is available through the world-wide-web at the following URI: * http://www.php.net/license/3_0.txt.  If you did not receive a copy of * the PHP License and are unable to obtain it through the web, please * send a note to license@php.net so we can mail you a copy immediately. * * @category   pear * @package    PEAR * @author     Greg Beaver <cellog@php.net> * @copyright  1997-2005 The PHP Group * @license    http://www.php.net/license/3_0.txt  PHP License 3.0 * @version    CVS: $Id: rw.php,v 1.1.2.1 2005/11/02 16:57:28 cellog Exp $ * @link       http://pear.php.net/package/PEAR * @since      File available since Release 1.4.0a10 *//** * Base class */require_once 'PEAR/Task/Replace.php';/** * Abstracts the replace task xml. * @category   pear * @package    PEAR * @author     Greg Beaver <cellog@php.net> * @copyright  1997-2005 The PHP Group * @license    http://www.php.net/license/3_0.txt  PHP License 3.0 * @version    Release: @package_version@ * @link       http://pear.php.net/package/PEAR * @since      Class available since Release 1.4.0a10 */class PEAR_Task_Replace_rw extends PEAR_Task_Replace{    function PEAR_Task_Replace_rw(&$pkg, &$config, &$logger, $fileXml)    {        parent::PEAR_Task_Common($config, $logger, PEAR_TASK_PACKAGE);        $this->_contents = $fileXml;        $this->_pkg = &$pkg;        $this->_params = array();    }    function validate()    {        return $this->validateXml($this->_pkg, $this->_params, $this->config, $this->_contents);    }    function setInfo($from, $to, $type)    {        $this->_params = array('attribs' => array('from' => $from, 'to' => $to, 'type' => $type));    }    function getName()    {        return 'replace';    }    function getXml()    {        return $this->_params;    }}?>

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?