Back to index

php5  5.3.10
Public Member Functions | Protected Attributes
PEAR2\Pyrus\Developer\CoverageAnalyzer\Web\Controller Class Reference

List of all members.

Public Member Functions

 __construct (View $view, $rooturl)
 route ()
 getFileLink ($file, $test=null, $line=null)
 getTOCLink ($test=false)
 getDatabase ()

Protected Attributes

 $view
 $sqlite
 $rooturl

Detailed Description

Definition at line 18 of file pear2coverage.phar.php.


Constructor & Destructor Documentation

Definition at line 23 of file pear2coverage.phar.php.

    {

Here is the call graph for this function:


Member Function Documentation

Definition at line 86 of file pear2coverage.phar.php.

                                                     {
PEAR2\Pyrus\Developer\CoverageAnalyzer\Web\Controller::getFileLink ( file,
test = null,
line = null 
)

Definition at line 62 of file pear2coverage.phar.php.

                   {
            return $this->rooturl . '?file=' . urlencode($file) . '&line=' . $line;
        }
        if ($test) {
            return $this->rooturl . '?file=' . urlencode($file) . '&test=' . $test;
        }
        return $this->rooturl . '?file=' . urlencode($file);
    }

    function getTOCLink($test = false)

Definition at line 73 of file pear2coverage.phar.php.

                             {
            return $this->rooturl;
        }
        if ($test === true) {
            return $this->rooturl . '?test=TOC';
        }
        if ($test) {
            return $this->rooturl . '?test=' . urlencode($test);
        }
    }

    function getDatabase()

Definition at line 30 of file pear2coverage.phar.php.

                                           {
            if (isset($_POST['setdatabase'])) {
                if (file_exists($_POST['setdatabase'])) {
                    $this->sqlite = new \Sqlite3($_POST['setdatabase']);
                    $_SESSION['fullpath'] = $_POST['setdatabase'];
                    return $this->view->TOC($this->sqlite);
                }
            }
            return $this->getDatabase();
        } else {
            $this->sqlite = new \Sqlite3($_POST['setdatabase']);
            if (isset($_GET['test'])) {
                if ($_GET['test'] === 'TOC') {
                    return $this->view->testTOC($this->sqlite);
                }
                if (isset($_GET['file'])) {
                    return $this->view->fileCoverage($this->sqlite, $_GET['file'], $_GET['test']);
                }
                return $this->view->testTOC($this->sqlite, $_GET['test']);
            }
            if (isset($_GET['file'])) {
                if (isset($_GET['line'])) {
                    return $this->view->fileLineTOC($this->sqlite, $_GET['file'], $_GET['line']);
                }
                return $this->view->fileCoverage($this->sqlite, $_GET['file']);
            }
            return $this->view->TOC($this->sqlite);
        }
    }

    function getFileLink($file, $test = null, $line = null)

Member Data Documentation

Definition at line 21 of file pear2coverage.phar.php.

Definition at line 20 of file pear2coverage.phar.php.

Definition at line 19 of file pear2coverage.phar.php.


The documentation for this class was generated from the following file: