ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
TableDiffFormatter Class Reference
+ Inheritance diagram for TableDiffFormatter:
+ Collaboration diagram for TableDiffFormatter:

Public Member Functions

 __construct ()
 
 _block_header ($xbeg, $xlen, $ybeg, $ylen)
 
 _start_block ($header)
 
 _end_block ()
 
 _lines ($lines, $prefix=' ', $color='white')
 
 addedLine ($line)
 
 deletedLine ($line)
 
 contextLine ($line)
 
 emptyLine ()
 
 _added ($lines)
 
 _deleted ($lines)
 
 _context ($lines)
 
 _changed ($orig, $closing)
 
- Public Member Functions inherited from DiffFormatter
 format ($diff)
 Format a diff. More...
 
 _block ($xbeg, $xlen, $ybeg, $ylen, &$edits)
 
 _start_diff ()
 
 _end_diff ()
 
 _block_header ($xbeg, $xlen, $ybeg, $ylen)
 
 _start_block ($header)
 
 _end_block ()
 
 _lines ($lines, $prefix=' ')
 
 _context ($lines)
 
 _added ($lines)
 
 _deleted ($lines)
 
 _changed ($orig, $closing)
 

Additional Inherited Members

- Data Fields inherited from DiffFormatter
 $leading_context_lines = 0
 Number of leading context "lines" to preserve. More...
 
 $trailing_context_lines = 0
 Number of trailing context "lines" to preserve. More...
 

Detailed Description

Definition at line 1872 of file class.WordLevelDiff.php.

Constructor & Destructor Documentation

◆ __construct()

TableDiffFormatter::__construct ( )

Definition at line 1874 of file class.WordLevelDiff.php.

1887 {

Member Function Documentation

◆ _added()

TableDiffFormatter::_added (   $lines)

Definition at line 1923 of file class.WordLevelDiff.php.

1923  {$line}</td>";
1924  }
1925 
1926  # HTML-escape parameter before calling this
1927  public function contextLine($line)
1928  {
1929  return "<td> </td><td class='diff-context'>{$line}</td>";

◆ _block_header()

TableDiffFormatter::_block_header (   $xbeg,
  $xlen,
  $ybeg,
  $ylen 
)

Definition at line 1880 of file class.WordLevelDiff.php.

1887 {

◆ _changed()

TableDiffFormatter::_changed (   $orig,
  $closing 
)

Definition at line 1948 of file class.WordLevelDiff.php.

1954  {
1955  foreach ($lines as $line) {
1956  echo '<tr>' .
1957  $this->contextLine(htmlspecialchars($line)) .
1958  $this->contextLine(htmlspecialchars($line)) . "</tr>\n";
1959  }
1960  }
1961 
1962  public function _changed($orig, $closing)
1963  {
1964  $fname = 'TableDiffFormatter::_changed';
1965  //wfProfileIn( $fname );
1966 
1967  $diff = new WordLevelDiff($orig, $closing);
1968  $del = $diff->orig();
1969  $add = $diff->closing();
1970 
_changed($orig, $closing)

◆ _context()

TableDiffFormatter::_context (   $lines)

Definition at line 1939 of file class.WordLevelDiff.php.

1939  {
1940  echo '<tr>' . $this->emptyLine() .
1941  $this->addedLine(htmlspecialchars($line)) . "</tr>\n";
1942  }
1943  }
1944 
1945  public function _deleted($lines)
1946  {

◆ _deleted()

TableDiffFormatter::_deleted (   $lines)

Definition at line 1931 of file class.WordLevelDiff.php.

1933  {
1934  return '<td colspan="2">&nbsp;</td>';
1935  }
1936 
1937  public function _added($lines)

◆ _end_block()

TableDiffFormatter::_end_block ( )

Definition at line 1892 of file class.WordLevelDiff.php.

1895  {

◆ _lines()

TableDiffFormatter::_lines (   $lines,
  $prefix = ' ',
  $color = 'white' 
)

Definition at line 1896 of file class.WordLevelDiff.php.

1902  {

◆ _start_block()

TableDiffFormatter::_start_block (   $header)

Definition at line 1887 of file class.WordLevelDiff.php.

References DifferenceEngine\__construct().

1887 {
1888  public function __construct()
1889  {
1890  $this->leading_context_lines = 2;
+ Here is the call graph for this function:

◆ addedLine()

TableDiffFormatter::addedLine (   $line)

Definition at line 1901 of file class.WordLevelDiff.php.

References $header.

1902  {
1903  echo $header;
1904  }

◆ contextLine()

TableDiffFormatter::contextLine (   $line)

Definition at line 1913 of file class.WordLevelDiff.php.

1916  {

◆ deletedLine()

TableDiffFormatter::deletedLine (   $line)

Definition at line 1907 of file class.WordLevelDiff.php.

1907  {
1908  }
1909 
1910  public function _lines($lines, $prefix = ' ', $color = 'white')
_lines($lines, $prefix=' ', $color='white')

◆ emptyLine()

TableDiffFormatter::emptyLine ( )

Definition at line 1918 of file class.WordLevelDiff.php.

1922  {

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