classes/phing/types/PatternSet.php
private function readPatterns(PhingFile $patternfile, &$patternlist, Project $p)
    {
        $patternReader = null;
        try {
            // Get a FileReader
            $patternReader = new BufferedReader(new FileReader($patternfile));

            // Create one NameEntry in the appropriate pattern list for each
            // line in the file.
            $line = $patternReader->readLine();
            while ($line !== null) {
                if (!empty($line)) {
                    $line = $p->replaceProperties($line);
                    $this->addPatternToList($patternlist)->setName($line);
                }
                $line = $patternReader->readLine();
            }
        } catch (IOException $ioe) {
            $msg = "An error occurred while reading from pattern file: " . $patternfile->__toString();
            if ($patternReader) {
                $patternReader->close();
            }
            throw new BuildException($msg, $ioe);
        }

        $patternReader->close();
    }
private function readPatterns(PhingFile $patternfile, &$patternlist, Project $p)
    {
        $patternReader = null;
        try {
            // Get a FileReader
            $patternReader = new BufferedReader(new FileReader($patternfile));

            // Create one NameEntry in the appropriate pattern list for each
            // line in the file.
            $line = $patternReader->readLine();
            while ($line !== null) {
                if (!empty($line)) {
                    $line = $p->replaceProperties($line);
                    $this->addPatternToList($patternlist)->setName($line);
                }
                $line = $patternReader->readLine();
            }
        } catch (IOException $ioe) {
            $msg = "An error occurred while reading from pattern file: " . $patternfile->__toString();
            if ($patternReader) {
                $patternReader->close();
            }
            throw new BuildException($msg, $ioe);
        }

        $patternReader->close();
    }
private function readPatterns ( PhingFile $ patternfile , & $ patternlist , Project $ p ) { $ patternReader = null ; try { // Get a FileReader $ patternReader = new BufferedReader ( new FileReader ( $ patternfile ) ) ; // Create one NameEntry in the appropriate pattern list for each // line in the file. $ line = $ patternReader -> readLine ( ) ; while ( $ line !== null ) { if ( ! empty ( $ line ) ) { $ line = $ p -> replaceProperties ( $ line ) ; $ this -> addPatternToList ( $ patternlist ) -> setName ( $ line ) ; } $ line = $ patternReader -> readLine ( ) ; } } catch ( IOException $ ioe ) { $ msg = "An error occurred while reading from pattern file: " . $ patternfile -> __toString ( ) ; if ( $ patternReader ) { $ patternReader -> close ( ) ; } throw new BuildException ( $ msg , $ ioe ) ; } $ patternReader -> close ( ) ; }
Reads path matching patterns from a file and adds them to the
includes or excludes list

@param PhingFile $patternfile
@param $patternlist
@param Project $p

@throws BuildException
Reads path matching patterns from a file and adds them to the includes or excludes list