FeaturePhp/Artifact/TracingLinkRenderer.php
public function _render($textOnly) {
        $tracingLinkNum = count($this->tracingLinks);
        $str = "";

        if ($textOnly) {
            $str .= "\nFeature Traceability\n====================\n" .
                 "The following $tracingLinkNum tracing links were found:\n\n";
            $maxLen = fphp\Helper\_String::getMaxLength($this->tracingLinks, "getFeatureName")
                    + fphp\Helper\_String::getMaxLength($this->tracingLinks, "getType");
            foreach ($this->tracingLinks as $tracingLink)
                $str .= $this->analyzeTracingLink($tracingLink, true, $maxLen);
        } else {
            $str .= "<h2>Feature Traceability</h2>";
            $str .= "<p>The following $tracingLinkNum tracing links were found:</p>";
            $str .= "<table cellpadding='2'>";
            $str .= "<tr align='left'><th>Feature</th><th>Type</th><th>Source</th><th>Target</th></tr>";
            foreach ($this->tracingLinks as $tracingLink)
                $str .= $this->analyzeTracingLink($tracingLink);
            $str .= "</table>";
        }
        
        return $str;
    }
public function _render($textOnly) {
        $tracingLinkNum = count($this->tracingLinks);
        $str = "";

        if ($textOnly) {
            $str .= "\nFeature Traceability\n====================\n" .
                 "The following $tracingLinkNum tracing links were found:\n\n";
            $maxLen = fphp\Helper\_String::getMaxLength($this->tracingLinks, "getFeatureName")
                    + fphp\Helper\_String::getMaxLength($this->tracingLinks, "getType");
            foreach ($this->tracingLinks as $tracingLink)
                $str .= $this->analyzeTracingLink($tracingLink, true, $maxLen);
        } else {
            $str .= "<h2>Feature Traceability</h2>";
            $str .= "<p>The following $tracingLinkNum tracing links were found:</p>";
            $str .= "<table cellpadding='2'>";
            $str .= "<tr align='left'><th>Feature</th><th>Type</th><th>Source</th><th>Target</th></tr>";
            foreach ($this->tracingLinks as $tracingLink)
                $str .= $this->analyzeTracingLink($tracingLink);
            $str .= "</table>";
        }
        
        return $str;
    }
public function _render ( $ textOnly ) { $ tracingLinkNum = count ( $ this -> tracingLinks ) ; $ str = "" ; if ( $ textOnly ) { $ str .= "\nFeature Traceability\n====================\n" . "The following $tracingLinkNum tracing links were found:\n\n" ; $ maxLen = fphp \ Helper \ _String :: getMaxLength ( $ this -> tracingLinks , "getFeatureName" ) + fphp \ Helper \ _String :: getMaxLength ( $ this -> tracingLinks , "getType" ) ; foreach ( $ this -> tracingLinks as $ tracingLink ) $ str .= $ this -> analyzeTracingLink ( $ tracingLink , true , $ maxLen ) ; } else { $ str .= "<h2>Feature Traceability</h2>" ; $ str .= "<p>The following $tracingLinkNum tracing links were found:</p>" ; $ str .= "<table cellpadding='2'>" ; $ str .= "<tr align='left'><th>Feature</th><th>Type</th><th>Source</th><th>Target</th></tr>" ; foreach ( $ this -> tracingLinks as $ tracingLink ) $ str .= $ this -> analyzeTracingLink ( $ tracingLink ) ; $ str .= "</table>" ; } return $ str ; }
Returns the tracing link analysis.
@param bool $textOnly whether to render text or HTML
@return string
Returns the tracing link analysis .