XoopsModules25x/apcal

View on GitHub
include/Text_Diff.php

Summary

Maintainability
F
4 days
Test Coverage

File Text_Diff.php has 484 lines of code (exceeds 250 allowed). Consider refactoring.
Open

<?php

/**
 * Text_Diff
 *
Severity: Minor
Found in include/Text_Diff.php - About 7 hrs to fix

    Function _shiftBoundaries has a Cognitive Complexity of 42 (exceeds 5 allowed). Consider refactoring.
    Open

        public function _shiftBoundaries($lines, &$changed, $other_changed)
        {
            $i = 0;
            $j = 0;
    
    
    Severity: Minor
    Found in include/Text_Diff.php - About 6 hrs to fix

    Cognitive Complexity

    Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

    A method's cognitive complexity is based on a few simple rules:

    • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
    • Code is considered more complex for each "break in the linear flow of the code"
    • Code is considered more complex when "flow breaking structures are nested"

    Further reading

    Function _diag has a Cognitive Complexity of 36 (exceeds 5 allowed). Consider refactoring.
    Open

        public function _diag($xoff, $xlim, $yoff, $ylim, $nchunks)
        {
            $flip = false;
    
            if ($xlim - $xoff > $ylim - $yoff) {
    Severity: Minor
    Found in include/Text_Diff.php - About 5 hrs to fix

    Cognitive Complexity

    Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

    A method's cognitive complexity is based on a few simple rules:

    • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
    • Code is considered more complex for each "break in the linear flow of the code"
    • Code is considered more complex when "flow breaking structures are nested"

    Further reading

    Function diff has a Cognitive Complexity of 34 (exceeds 5 allowed). Consider refactoring.
    Open

        public function diff($from_lines, $to_lines)
        {
            $n_from = count($from_lines);
            $n_to   = count($to_lines);
    
    
    Severity: Minor
    Found in include/Text_Diff.php - About 5 hrs to fix

    Cognitive Complexity

    Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

    A method's cognitive complexity is based on a few simple rules:

    • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
    • Code is considered more complex for each "break in the linear flow of the code"
    • Code is considered more complex when "flow breaking structures are nested"

    Further reading

    The class Text_Diff_Engine_native has an overall complexity of 95 which is very high. The configured complexity threshold is 50.
    Open

    class Text_Diff_Engine_native
    {
        /**
         * @param $from_lines
         * @param $to_lines
    Severity: Minor
    Found in include/Text_Diff.php by phpmd

    Method diff has 73 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        public function diff($from_lines, $to_lines)
        {
            $n_from = count($from_lines);
            $n_to   = count($to_lines);
    
    
    Severity: Major
    Found in include/Text_Diff.php - About 2 hrs to fix

      Method _shiftBoundaries has 65 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          public function _shiftBoundaries($lines, &$changed, $other_changed)
          {
              $i = 0;
              $j = 0;
      
      
      Severity: Major
      Found in include/Text_Diff.php - About 2 hrs to fix

        Method _diag has 64 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            public function _diag($xoff, $xlim, $yoff, $ylim, $nchunks)
            {
                $flip = false;
        
                if ($xlim - $xoff > $ylim - $yoff) {
        Severity: Major
        Found in include/Text_Diff.php - About 2 hrs to fix

          Function _compareseq has a Cognitive Complexity of 14 (exceeds 5 allowed). Consider refactoring.
          Open

              public function _compareseq($xoff, $xlim, $yoff, $ylim)
              {
                  /* Slide down the bottom initial diagonal. */
                  while ($xoff < $xlim && $yoff < $ylim && $this->xv[$xoff] == $this->yv[$yoff]) {
                      ++$xoff;
          Severity: Minor
          Found in include/Text_Diff.php - About 1 hr to fix

          Cognitive Complexity

          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

          A method's cognitive complexity is based on a few simple rules:

          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
          • Code is considered more complex for each "break in the linear flow of the code"
          • Code is considered more complex when "flow breaking structures are nested"

          Further reading

          Method _compareseq has 29 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

              public function _compareseq($xoff, $xlim, $yoff, $ylim)
              {
                  /* Slide down the bottom initial diagonal. */
                  while ($xoff < $xlim && $yoff < $ylim && $this->xv[$xoff] == $this->yv[$yoff]) {
                      ++$xoff;
          Severity: Minor
          Found in include/Text_Diff.php - About 1 hr to fix

            Method _diag has 5 arguments (exceeds 4 allowed). Consider refactoring.
            Open

                public function _diag($xoff, $xlim, $yoff, $ylim, $nchunks)
            Severity: Minor
            Found in include/Text_Diff.php - About 35 mins to fix

              Function _check has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
              Open

                  public function _check($from_lines, $to_lines)
                  {
                      if (serialize($from_lines) != serialize($this->getOriginal())) {
                          trigger_error("Reconstructed original doesn't match", E_USER_ERROR);
                      }
              Severity: Minor
              Found in include/Text_Diff.php - About 35 mins to fix

              Cognitive Complexity

              Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

              A method's cognitive complexity is based on a few simple rules:

              • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
              • Code is considered more complex for each "break in the linear flow of the code"
              • Code is considered more complex when "flow breaking structures are nested"

              Further reading

              Function _lcsPos has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
              Open

                  public function _lcsPos($ypos)
                  {
                      $end = $this->lcs;
                      if ($end == 0 || $ypos > $this->seq[$end]) {
                          $this->seq[++$this->lcs] = $ypos;
              Severity: Minor
              Found in include/Text_Diff.php - About 25 mins to fix

              Cognitive Complexity

              Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

              A method's cognitive complexity is based on a few simple rules:

              • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
              • Code is considered more complex for each "break in the linear flow of the code"
              • Code is considered more complex when "flow breaking structures are nested"

              Further reading

              The method _shiftBoundaries() has 108 lines of code. Current threshold is set to 100. Avoid really long methods.
              Open

                  public function _shiftBoundaries($lines, &$changed, $other_changed)
                  {
                      $i = 0;
                      $j = 0;
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              The method _compareseq() has an NPath complexity of 288. The configured NPath complexity threshold is 200.
              Open

                  public function _compareseq($xoff, $xlim, $yoff, $ylim)
                  {
                      /* Slide down the bottom initial diagonal. */
                      while ($xoff < $xlim && $yoff < $ylim && $this->xv[$xoff] == $this->yv[$yoff]) {
                          ++$xoff;
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              NPathComplexity

              Since: 0.1

              The NPath complexity of a method is the number of acyclic execution paths through that method. A threshold of 200 is generally considered the point where measures should be taken to reduce complexity.

              Example

              class Foo {
                  function bar() {
                      // lots of complicated code
                  }
              }

              Source https://phpmd.org/rules/codesize.html#npathcomplexity

              The method _diag() has an NPath complexity of 14208. The configured NPath complexity threshold is 200.
              Open

                  public function _diag($xoff, $xlim, $yoff, $ylim, $nchunks)
                  {
                      $flip = false;
              
                      if ($xlim - $xoff > $ylim - $yoff) {
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              NPathComplexity

              Since: 0.1

              The NPath complexity of a method is the number of acyclic execution paths through that method. A threshold of 200 is generally considered the point where measures should be taken to reduce complexity.

              Example

              class Foo {
                  function bar() {
                      // lots of complicated code
                  }
              }

              Source https://phpmd.org/rules/codesize.html#npathcomplexity

              The method diff() has an NPath complexity of 130176. The configured NPath complexity threshold is 200.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              NPathComplexity

              Since: 0.1

              The NPath complexity of a method is the number of acyclic execution paths through that method. A threshold of 200 is generally considered the point where measures should be taken to reduce complexity.

              Example

              class Foo {
                  function bar() {
                      // lots of complicated code
                  }
              }

              Source https://phpmd.org/rules/codesize.html#npathcomplexity

              The method _shiftBoundaries() has an NPath complexity of 73711. The configured NPath complexity threshold is 200.
              Open

                  public function _shiftBoundaries($lines, &$changed, $other_changed)
                  {
                      $i = 0;
                      $j = 0;
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              NPathComplexity

              Since: 0.1

              The NPath complexity of a method is the number of acyclic execution paths through that method. A threshold of 200 is generally considered the point where measures should be taken to reduce complexity.

              Example

              class Foo {
                  function bar() {
                      // lots of complicated code
                  }
              }

              Source https://phpmd.org/rules/codesize.html#npathcomplexity

              The method _shiftBoundaries() has a Cyclomatic Complexity of 28. The configured cyclomatic complexity threshold is 10.
              Open

                  public function _shiftBoundaries($lines, &$changed, $other_changed)
                  {
                      $i = 0;
                      $j = 0;
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CyclomaticComplexity

              Since: 0.1

              Complexity is determined by the number of decision points in a method plus one for the method entry. The decision points are 'if', 'while', 'for', and 'case labels'. Generally, 1-4 is low complexity, 5-7 indicates moderate complexity, 8-10 is high complexity, and 11+ is very high complexity.

              Example

              // Cyclomatic Complexity = 11
              class Foo {
              1   public function example() {
              2       if ($a == $b) {
              3           if ($a1 == $b1) {
                              fiddle();
              4           } elseif ($a2 == $b2) {
                              fiddle();
                          } else {
                              fiddle();
                          }
              5       } elseif ($c == $d) {
              6           while ($c == $d) {
                              fiddle();
                          }
              7        } elseif ($e == $f) {
              8           for ($n = 0; $n < $h; $n++) {
                              fiddle();
                          }
                      } else {
                          switch ($z) {
              9               case 1:
                                  fiddle();
                                  break;
              10              case 2:
                                  fiddle();
                                  break;
              11              case 3:
                                  fiddle();
                                  break;
                              default:
                                  fiddle();
                                  break;
                          }
                      }
                  }
              }

              Source https://phpmd.org/rules/codesize.html#cyclomaticcomplexity

              The method diff() has a Cyclomatic Complexity of 29. The configured cyclomatic complexity threshold is 10.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CyclomaticComplexity

              Since: 0.1

              Complexity is determined by the number of decision points in a method plus one for the method entry. The decision points are 'if', 'while', 'for', and 'case labels'. Generally, 1-4 is low complexity, 5-7 indicates moderate complexity, 8-10 is high complexity, and 11+ is very high complexity.

              Example

              // Cyclomatic Complexity = 11
              class Foo {
              1   public function example() {
              2       if ($a == $b) {
              3           if ($a1 == $b1) {
                              fiddle();
              4           } elseif ($a2 == $b2) {
                              fiddle();
                          } else {
                              fiddle();
                          }
              5       } elseif ($c == $d) {
              6           while ($c == $d) {
                              fiddle();
                          }
              7        } elseif ($e == $f) {
              8           for ($n = 0; $n < $h; $n++) {
                              fiddle();
                          }
                      } else {
                          switch ($z) {
              9               case 1:
                                  fiddle();
                                  break;
              10              case 2:
                                  fiddle();
                                  break;
              11              case 3:
                                  fiddle();
                                  break;
                              default:
                                  fiddle();
                                  break;
                          }
                      }
                  }
              }

              Source https://phpmd.org/rules/codesize.html#cyclomaticcomplexity

              The method _compareseq() has a Cyclomatic Complexity of 13. The configured cyclomatic complexity threshold is 10.
              Open

                  public function _compareseq($xoff, $xlim, $yoff, $ylim)
                  {
                      /* Slide down the bottom initial diagonal. */
                      while ($xoff < $xlim && $yoff < $ylim && $this->xv[$xoff] == $this->yv[$yoff]) {
                          ++$xoff;
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CyclomaticComplexity

              Since: 0.1

              Complexity is determined by the number of decision points in a method plus one for the method entry. The decision points are 'if', 'while', 'for', and 'case labels'. Generally, 1-4 is low complexity, 5-7 indicates moderate complexity, 8-10 is high complexity, and 11+ is very high complexity.

              Example

              // Cyclomatic Complexity = 11
              class Foo {
              1   public function example() {
              2       if ($a == $b) {
              3           if ($a1 == $b1) {
                              fiddle();
              4           } elseif ($a2 == $b2) {
                              fiddle();
                          } else {
                              fiddle();
                          }
              5       } elseif ($c == $d) {
              6           while ($c == $d) {
                              fiddle();
                          }
              7        } elseif ($e == $f) {
              8           for ($n = 0; $n < $h; $n++) {
                              fiddle();
                          }
                      } else {
                          switch ($z) {
              9               case 1:
                                  fiddle();
                                  break;
              10              case 2:
                                  fiddle();
                                  break;
              11              case 3:
                                  fiddle();
                                  break;
                              default:
                                  fiddle();
                                  break;
                          }
                      }
                  }
              }

              Source https://phpmd.org/rules/codesize.html#cyclomaticcomplexity

              The method _diag() has a Cyclomatic Complexity of 20. The configured cyclomatic complexity threshold is 10.
              Open

                  public function _diag($xoff, $xlim, $yoff, $ylim, $nchunks)
                  {
                      $flip = false;
              
                      if ($xlim - $xoff > $ylim - $yoff) {
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CyclomaticComplexity

              Since: 0.1

              Complexity is determined by the number of decision points in a method plus one for the method entry. The decision points are 'if', 'while', 'for', and 'case labels'. Generally, 1-4 is low complexity, 5-7 indicates moderate complexity, 8-10 is high complexity, and 11+ is very high complexity.

              Example

              // Cyclomatic Complexity = 11
              class Foo {
              1   public function example() {
              2       if ($a == $b) {
              3           if ($a1 == $b1) {
                              fiddle();
              4           } elseif ($a2 == $b2) {
                              fiddle();
                          } else {
                              fiddle();
                          }
              5       } elseif ($c == $d) {
              6           while ($c == $d) {
                              fiddle();
                          }
              7        } elseif ($e == $f) {
              8           for ($n = 0; $n < $h; $n++) {
                              fiddle();
                          }
                      } else {
                          switch ($z) {
              9               case 1:
                                  fiddle();
                                  break;
              10              case 2:
                                  fiddle();
                                  break;
              11              case 3:
                                  fiddle();
                                  break;
                              default:
                                  fiddle();
                                  break;
                          }
                      }
                  }
              }

              Source https://phpmd.org/rules/codesize.html#cyclomaticcomplexity

              Avoid using undefined variables such as '$obj' which will lead to PHP notices.
              Open

                          $rev = clone $obj;
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UndefinedVariable

              Since: 2.8.0

              Detects when a variable is used that has not been defined before.

              Example

              class Foo
              {
                  private function bar()
                  {
                      // $message is undefined
                      echo $message;
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#undefinedvariable

              Avoid using undefined variables such as '$ymatches' which will lead to PHP notices.
              Open

                              $ymatches[$this->yv[$i]][] = $i;
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UndefinedVariable

              Since: 2.8.0

              Detects when a variable is used that has not been defined before.

              Example

              class Foo
              {
                  private function bar()
                  {
                      // $message is undefined
                      echo $message;
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#undefinedvariable

              Avoid using undefined variables such as '$seps' which will lead to PHP notices.
              Open

                      return array($this->lcs, $seps);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UndefinedVariable

              Since: 2.8.0

              Detects when a variable is used that has not been defined before.

              Example

              class Foo
              {
                  private function bar()
                  {
                      // $message is undefined
                      echo $message;
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#undefinedvariable

              Avoid using undefined variables such as '$yhash' which will lead to PHP notices.
              Open

                          if ($this->xchanged[$xi] = empty($yhash[$line])) {
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UndefinedVariable

              Since: 2.8.0

              Detects when a variable is used that has not been defined before.

              Example

              class Foo
              {
                  private function bar()
                  {
                      // $message is undefined
                      echo $message;
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#undefinedvariable

              Avoid using undefined variables such as '$ymids' which will lead to PHP notices.
              Open

                                      $ymids[$k] = $ymids[$k - 1];
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UndefinedVariable

              Since: 2.8.0

              Detects when a variable is used that has not been defined before.

              Example

              class Foo
              {
                  private function bar()
                  {
                      // $message is undefined
                      echo $message;
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#undefinedvariable

              Avoid using undefined variables such as '$ymids' which will lead to PHP notices.
              Open

                                      $ymids[$k] = $ymids[$k - 1];
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UndefinedVariable

              Since: 2.8.0

              Detects when a variable is used that has not been defined before.

              Example

              class Foo
              {
                  private function bar()
                  {
                      // $message is undefined
                      echo $message;
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#undefinedvariable

              Avoid using undefined variables such as '$seps' which will lead to PHP notices.
              Open

                      $seps[] = $flip ? array($ylim, $xlim) : array($xlim, $ylim);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UndefinedVariable

              Since: 2.8.0

              Detects when a variable is used that has not been defined before.

              Example

              class Foo
              {
                  private function bar()
                  {
                      // $message is undefined
                      echo $message;
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#undefinedvariable

              Avoid using undefined variables such as '$ymatches' which will lead to PHP notices.
              Open

                              $matches = $ymatches[$line];
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UndefinedVariable

              Since: 2.8.0

              Detects when a variable is used that has not been defined before.

              Example

              class Foo
              {
                  private function bar()
                  {
                      // $message is undefined
                      echo $message;
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#undefinedvariable

              Avoid using undefined variables such as '$ymids' which will lead to PHP notices.
              Open

                      $ymid   = $ymids[$this->lcs];
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UndefinedVariable

              Since: 2.8.0

              Detects when a variable is used that has not been defined before.

              Example

              class Foo
              {
                  private function bar()
                  {
                      // $message is undefined
                      echo $message;
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#undefinedvariable

              Avoid using undefined variables such as '$ymids' which will lead to PHP notices.
              Open

                      $ymids[0]     = array();
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UndefinedVariable

              Since: 2.8.0

              Detects when a variable is used that has not been defined before.

              Example

              class Foo
              {
                  private function bar()
                  {
                      // $message is undefined
                      echo $message;
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#undefinedvariable

              Avoid using undefined variables such as '$ymatches' which will lead to PHP notices.
              Open

                              if (empty($ymatches[$line])) {
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UndefinedVariable

              Since: 2.8.0

              Detects when a variable is used that has not been defined before.

              Example

              class Foo
              {
                  private function bar()
                  {
                      // $message is undefined
                      echo $message;
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#undefinedvariable

              Avoid using undefined variables such as '$ymids' which will lead to PHP notices.
              Open

                                  $ymids[$i][$chunk - 1] = $this->seq[$i];
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UndefinedVariable

              Since: 2.8.0

              Detects when a variable is used that has not been defined before.

              Example

              class Foo
              {
                  private function bar()
                  {
                      // $message is undefined
                      echo $message;
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#undefinedvariable

              Avoid using undefined variables such as '$ymatches' which will lead to PHP notices.
              Open

                              $ymatches[$this->xv[$i]][] = $i;
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UndefinedVariable

              Since: 2.8.0

              Detects when a variable is used that has not been defined before.

              Example

              class Foo
              {
                  private function bar()
                  {
                      // $message is undefined
                      echo $message;
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#undefinedvariable

              Avoid using undefined variables such as '$seps' which will lead to PHP notices.
              Open

                      $seps[] = $flip ? array($yoff, $xoff) : array($xoff, $yoff);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UndefinedVariable

              Since: 2.8.0

              Detects when a variable is used that has not been defined before.

              Example

              class Foo
              {
                  private function bar()
                  {
                      // $message is undefined
                      echo $message;
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#undefinedvariable

              Avoid using undefined variables such as '$ymids' which will lead to PHP notices.
              Open

                                      $ymids[$k] = $ymids[$k - 1];
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UndefinedVariable

              Since: 2.8.0

              Detects when a variable is used that has not been defined before.

              Example

              class Foo
              {
                  private function bar()
                  {
                      // $message is undefined
                      echo $message;
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#undefinedvariable

              Avoid using undefined variables such as '$ymids' which will lead to PHP notices.
              Open

                                      $ymids[$k] = $ymids[$k - 1];
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UndefinedVariable

              Since: 2.8.0

              Detects when a variable is used that has not been defined before.

              Example

              class Foo
              {
                  private function bar()
                  {
                      // $message is undefined
                      echo $message;
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#undefinedvariable

              Avoid using undefined variables such as '$xhash' which will lead to PHP notices.
              Open

                          if ($this->ychanged[$yi] = empty($xhash[$line])) {
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UndefinedVariable

              Since: 2.8.0

              Detects when a variable is used that has not been defined before.

              Example

              class Foo
              {
                  private function bar()
                  {
                      // $message is undefined
                      echo $message;
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#undefinedvariable

              Avoid using undefined variables such as '$yhash' which will lead to PHP notices.
              Open

                          $yhash[$line] = 1;
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UndefinedVariable

              Since: 2.8.0

              Detects when a variable is used that has not been defined before.

              Example

              class Foo
              {
                  private function bar()
                  {
                      // $message is undefined
                      echo $message;
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#undefinedvariable

              Avoid using undefined variables such as '$seps' which will lead to PHP notices.
              Open

                          $seps[] = $flip ? array($y1, $x1) : array($x1, $y1);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UndefinedVariable

              Since: 2.8.0

              Detects when a variable is used that has not been defined before.

              Example

              class Foo
              {
                  private function bar()
                  {
                      // $message is undefined
                      echo $message;
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#undefinedvariable

              Avoid using undefined variables such as '$xhash' which will lead to PHP notices.
              Open

                          $xhash[$from_lines[$xi]] = 1;
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UndefinedVariable

              Since: 2.8.0

              Detects when a variable is used that has not been defined before.

              Example

              class Foo
              {
                  private function bar()
                  {
                      // $message is undefined
                      echo $message;
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#undefinedvariable

              Missing class import via use statement (line '41', column '27').
              Open

                          $engine = new Text_Diff_Engine_native();
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              MissingImport

              Since: 2.7.0

              Importing all external classes in a file through use statements makes them clearly visible.

              Example

              function make() {
                  return new \stdClass();
              }

              Source http://phpmd.org/rules/cleancode.html#MissingImport

              Missing class import via use statement (line '39', column '27').
              Open

                          $engine = new Text_Diff_Engine_xdiff();
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              MissingImport

              Since: 2.7.0

              Importing all external classes in a file through use statements makes them clearly visible.

              Example

              function make() {
                  return new \stdClass();
              }

              Source http://phpmd.org/rules/cleancode.html#MissingImport

              Missing class import via use statement (line '301', column '36').
              Open

                                  $edits[] = new Text_Diff_Op_delete(array(substr($line, 1)));
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              MissingImport

              Since: 2.7.0

              Importing all external classes in a file through use statements makes them clearly visible.

              Example

              function make() {
                  return new \stdClass();
              }

              Source http://phpmd.org/rules/cleancode.html#MissingImport

              Missing class import via use statement (line '820', column '31').
              Open

                      return $reverse = new Text_Diff_Op_copy($this->final, $this->orig);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              MissingImport

              Since: 2.7.0

              Importing all external classes in a file through use statements makes them clearly visible.

              Example

              function make() {
                  return new \stdClass();
              }

              Source http://phpmd.org/rules/cleancode.html#MissingImport

              Missing class import via use statement (line '874', column '31').
              Open

                      return $reverse = new Text_Diff_Op_delete($this->final);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              MissingImport

              Since: 2.7.0

              Importing all external classes in a file through use statements makes them clearly visible.

              Example

              function make() {
                  return new \stdClass();
              }

              Source http://phpmd.org/rules/cleancode.html#MissingImport

              Missing class import via use statement (line '293', column '36').
              Open

                                  $edits[] = new Text_Diff_Op_copy(array(substr($line, 1)));
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              MissingImport

              Since: 2.7.0

              Importing all external classes in a file through use statements makes them clearly visible.

              Example

              function make() {
                  return new \stdClass();
              }

              Source http://phpmd.org/rules/cleancode.html#MissingImport

              Missing class import via use statement (line '297', column '36').
              Open

                                  $edits[] = new Text_Diff_Op_add(array(substr($line, 1)));
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              MissingImport

              Since: 2.7.0

              Importing all external classes in a file through use statements makes them clearly visible.

              Example

              function make() {
                  return new \stdClass();
              }

              Source http://phpmd.org/rules/cleancode.html#MissingImport

              Missing class import via use statement (line '412', column '32').
              Open

                              $edits[] = new Text_Diff_Op_copy($copy);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              MissingImport

              Since: 2.7.0

              Importing all external classes in a file through use statements makes them clearly visible.

              Example

              function make() {
                  return new \stdClass();
              }

              Source http://phpmd.org/rules/cleancode.html#MissingImport

              Missing class import via use statement (line '427', column '32').
              Open

                              $edits[] = new Text_Diff_Op_change($delete, $add);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              MissingImport

              Since: 2.7.0

              Importing all external classes in a file through use statements makes them clearly visible.

              Example

              function make() {
                  return new \stdClass();
              }

              Source http://phpmd.org/rules/cleancode.html#MissingImport

              Missing class import via use statement (line '431', column '32').
              Open

                              $edits[] = new Text_Diff_Op_add($add);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              MissingImport

              Since: 2.7.0

              Importing all external classes in a file through use statements makes them clearly visible.

              Example

              function make() {
                  return new \stdClass();
              }

              Source http://phpmd.org/rules/cleancode.html#MissingImport

              Missing class import via use statement (line '429', column '32').
              Open

                              $edits[] = new Text_Diff_Op_delete($delete);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              MissingImport

              Since: 2.7.0

              Importing all external classes in a file through use statements makes them clearly visible.

              Example

              function make() {
                  return new \stdClass();
              }

              Source http://phpmd.org/rules/cleancode.html#MissingImport

              The method __construct has a boolean flag argument $final, which is a certain sign of a Single Responsibility Principle violation.
              Open

                  public function __construct($orig, $final = false)
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              BooleanArgumentFlag

              Since: 1.4.0

              A boolean flag argument is a reliable indicator for a violation of the Single Responsibility Principle (SRP). You can fix this problem by extracting the logic in the boolean flag into its own class or method.

              Example

              class Foo {
                  public function bar($flag = true) {
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#booleanargumentflag

              Missing class import via use statement (line '902', column '31').
              Open

                      return $reverse = new Text_Diff_Op_change($this->final, $this->orig);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              MissingImport

              Since: 2.7.0

              Importing all external classes in a file through use statements makes them clearly visible.

              Example

              function make() {
                  return new \stdClass();
              }

              Source http://phpmd.org/rules/cleancode.html#MissingImport

              Missing class import via use statement (line '847', column '31').
              Open

                      return $reverse = new Text_Diff_Op_add($this->orig);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              MissingImport

              Since: 2.7.0

              Importing all external classes in a file through use statements makes them clearly visible.

              Example

              function make() {
                  return new \stdClass();
              }

              Source http://phpmd.org/rules/cleancode.html#MissingImport

              The method __construct uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
              Open

                      } else {
                          $engine = new Text_Diff_Engine_native();
                      }
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              ElseExpression

              Since: 1.4.0

              An if expression with an else branch is basically not necessary. You can rewrite the conditions in a way that the else clause is not necessary and the code becomes simpler to read. To achieve this, use early return statements, though you may need to split the code it several smaller methods. For very simple assignments you could also use the ternary operations.

              Example

              class Foo
              {
                  public function bar($flag)
                  {
                      if ($flag) {
                          // one branch
                      } else {
                          // another branch
                      }
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#elseexpression

              The method reverse uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
              Open

                      } else {
                          $rev = $this;
                      }
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              ElseExpression

              Since: 1.4.0

              An if expression with an else branch is basically not necessary. You can rewrite the conditions in a way that the else clause is not necessary and the code becomes simpler to read. To achieve this, use early return statements, though you may need to split the code it several smaller methods. For very simple assignments you could also use the ternary operations.

              Example

              class Foo
              {
                  public function bar($flag)
                  {
                      if ($flag) {
                          // one branch
                      } else {
                          // another branch
                      }
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#elseexpression

              The method _lcsPos uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
              Open

                          } else {
                              $end = $mid;
                          }
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              ElseExpression

              Since: 1.4.0

              An if expression with an else branch is basically not necessary. You can rewrite the conditions in a way that the else clause is not necessary and the code becomes simpler to read. To achieve this, use early return statements, though you may need to split the code it several smaller methods. For very simple assignments you could also use the ternary operations.

              Example

              class Foo
              {
                  public function bar($flag)
                  {
                      if ($flag) {
                          // one branch
                      } else {
                          // another branch
                      }
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#elseexpression

              The method _compareseq uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
              Open

                      } else {
                          /* This is ad hoc but seems to work well.  $nchunks =
                           * sqrt(min($xlim - $xoff, $ylim - $yoff) / 2.5); $nchunks =
                           * max(2,min(8,(int) $nchunks)); */
                          $nchunks = min(7, $xlim - $xoff, $ylim - $yoff) + 1;
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              ElseExpression

              Since: 1.4.0

              An if expression with an else branch is basically not necessary. You can rewrite the conditions in a way that the else clause is not necessary and the code becomes simpler to read. To achieve this, use early return statements, though you may need to split the code it several smaller methods. For very simple assignments you could also use the ternary operations.

              Example

              class Foo
              {
                  public function bar($flag)
                  {
                      if ($flag) {
                          // one branch
                      } else {
                          // another branch
                      }
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#elseexpression

              The method _diag uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
              Open

                      } else {
                          for ($i = $ylim - 1; $i >= $yoff; $i--) {
                              $ymatches[$this->yv[$i]][] = $i;
                          }
                      }
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              ElseExpression

              Since: 1.4.0

              An if expression with an else branch is basically not necessary. You can rewrite the conditions in a way that the else clause is not necessary and the code becomes simpler to read. To achieve this, use early return statements, though you may need to split the code it several smaller methods. For very simple assignments you could also use the ternary operations.

              Example

              class Foo
              {
                  public function bar($flag)
                  {
                      if ($flag) {
                          // one branch
                      } else {
                          // another branch
                      }
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#elseexpression

              Avoid assigning values to variables in if clauses and the like (line '384', column '17').
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              IfStatementAssignment

              Since: 2.7.0

              Assignments in if clauses and the like are considered a code smell. Assignments in PHP return the right operand as their result. In many cases, this is an expected behavior, but can lead to many difficult to spot bugs, especially when the right operand could result in zero, null or an empty string and the like.

              Example

              class Foo
              {
                  public function bar($flag)
                  {
                      if ($foo = 'bar') { // possible typo
                          // ...
                      }
                      if ($baz = 0) { // always false
                          // ...
                      }
                  }
              }

              Source http://phpmd.org/rules/cleancode.html#ifstatementassignment

              Avoid assigning values to variables in if clauses and the like (line '375', column '17').
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              IfStatementAssignment

              Since: 2.7.0

              Assignments in if clauses and the like are considered a code smell. Assignments in PHP return the right operand as their result. In many cases, this is an expected behavior, but can lead to many difficult to spot bugs, especially when the right operand could result in zero, null or an empty string and the like.

              Example

              class Foo
              {
                  public function bar($flag)
                  {
                      if ($foo = 'bar') { // possible typo
                          // ...
                      }
                      if ($baz = 0) { // always false
                          // ...
                      }
                  }
              }

              Source http://phpmd.org/rules/cleancode.html#ifstatementassignment

              The method _compareseq uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
              Open

                      } else {
                          /* Use the partitions to split this problem into subproblems. */
                          reset($seps);
                          $pt1 = $seps[0];
                          while ($pt2 = next($seps)) {
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              ElseExpression

              Since: 1.4.0

              An if expression with an else branch is basically not necessary. You can rewrite the conditions in a way that the else clause is not necessary and the code becomes simpler to read. To achieve this, use early return statements, though you may need to split the code it several smaller methods. For very simple assignments you could also use the ternary operations.

              Example

              class Foo
              {
                  public function bar($flag)
                  {
                      if ($flag) {
                          // one branch
                      } else {
                          // another branch
                      }
                  }
              }

              Source https://phpmd.org/rules/cleancode.html#elseexpression

              Avoid unused local variables such as '$obj'.
              Open

                          $rev = clone $obj;
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UnusedLocalVariable

              Since: 0.2

              Detects when a local variable is declared and/or assigned, but not used.

              Example

              class Foo {
                  public function doSomething()
                  {
                      $i = 5; // Unused
                  }
              }

              Source https://phpmd.org/rules/unusedcode.html#unusedlocalvariable

              Avoid unused parameters such as '$key'.
              Open

                  public function _trimNewlines(&$line, $key)
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UnusedFormalParameter

              Since: 0.2

              Avoid passing parameters to methods or constructors and then not using those parameters.

              Example

              class Foo
              {
                  private function bar($howdy)
                  {
                      // $howdy is not used
                  }
              }

              Source https://phpmd.org/rules/unusedcode.html#unusedformalparameter

              Avoid unused local variables such as '$reverse'.
              Open

                      return $reverse = new Text_Diff_Op_copy($this->final, $this->orig);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UnusedLocalVariable

              Since: 0.2

              Detects when a local variable is declared and/or assigned, but not used.

              Example

              class Foo {
                  public function doSomething()
                  {
                      $i = 5; // Unused
                  }
              }

              Source https://phpmd.org/rules/unusedcode.html#unusedlocalvariable

              Avoid unused local variables such as '$reverse'.
              Open

                      return $reverse = new Text_Diff_Op_change($this->final, $this->orig);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UnusedLocalVariable

              Since: 0.2

              Detects when a local variable is declared and/or assigned, but not used.

              Example

              class Foo {
                  public function doSomething()
                  {
                      $i = 5; // Unused
                  }
              }

              Source https://phpmd.org/rules/unusedcode.html#unusedlocalvariable

              Avoid unused local variables such as '$reverse'.
              Open

                      return $reverse = new Text_Diff_Op_add($this->orig);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UnusedLocalVariable

              Since: 0.2

              Detects when a local variable is declared and/or assigned, but not used.

              Example

              class Foo {
                  public function doSomething()
                  {
                      $i = 5; // Unused
                  }
              }

              Source https://phpmd.org/rules/unusedcode.html#unusedlocalvariable

              Avoid unused local variables such as '$junk'.
              Open

                              foreach ($matches as $junk => $y) {
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UnusedLocalVariable

              Since: 0.2

              Detects when a local variable is declared and/or assigned, but not used.

              Example

              class Foo {
                  public function doSomething()
                  {
                      $i = 5; // Unused
                  }
              }

              Source https://phpmd.org/rules/unusedcode.html#unusedlocalvariable

              Avoid unused local variables such as '$reverse'.
              Open

                      return $reverse = new Text_Diff_Op_delete($this->final);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              UnusedLocalVariable

              Since: 0.2

              Detects when a local variable is declared and/or assigned, but not used.

              Example

              class Foo {
                  public function doSomething()
                  {
                      $i = 5; // Unused
                  }
              }

              Source https://phpmd.org/rules/unusedcode.html#unusedlocalvariable

              Each class must be in a namespace of at least one level (a top-level vendor name)
              Open

              class Text_Diff_Engine_native
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Each class must be in a namespace of at least one level (a top-level vendor name)
              Open

              class Text_Diff_Op_copy extends Text_Diff_Op
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Each class must be in a namespace of at least one level (a top-level vendor name)
              Open

              class Text_Diff_Op_add extends Text_Diff_Op
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Each class must be in a namespace of at least one level (a top-level vendor name)
              Open

              class Text_Diff
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Each class must be in a namespace of at least one level (a top-level vendor name)
              Open

              class Text_Diff_Engine_xdiff
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Each class must be in a namespace of at least one level (a top-level vendor name)
              Open

              class Text_Diff_Op_delete extends Text_Diff_Op
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Each class must be in a namespace of at least one level (a top-level vendor name)
              Open

              class Text_Diff_Op_change extends Text_Diff_Op
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Each class must be in a namespace of at least one level (a top-level vendor name)
              Open

              class Text_Diff_Op
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Each class must be in a namespace of at least one level (a top-level vendor name)
              Open

              class Text_MappedDiff extends Text_Diff
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              The class Text_Diff is not named in CamelCase.
              Open

              class Text_Diff
              {
                  /**
                   * Array of changes.
                   *
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseClassName

              Since: 0.2

              It is considered best practice to use the CamelCase notation to name classes.

              Example

              class class_name {
              }

              Source

              The parameter $to_lines is not named in camelCase.
              Open

                  public function __construct($from_lines, $to_lines)
                  {
                      array_walk($from_lines, array($this, '_trimNewlines'));
                      array_walk($to_lines, array($this, '_trimNewlines'));
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseParameterName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name parameters.

              Example

              class ClassName {
                  public function doSomething($user_name) {
                  }
              }

              Source

              The property $_edits is not named in camelCase.
              Open

              class Text_Diff
              {
                  /**
                   * Array of changes.
                   *
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCasePropertyName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name attributes.

              Example

              class ClassName {
                  protected $property_name;
              }

              Source

              The parameter $from_lines is not named in camelCase.
              Open

                  public function __construct($from_lines, $to_lines)
                  {
                      array_walk($from_lines, array($this, '_trimNewlines'));
                      array_walk($to_lines, array($this, '_trimNewlines'));
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseParameterName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name parameters.

              Example

              class ClassName {
                  public function doSomething($user_name) {
                  }
              }

              Source

              The class Text_MappedDiff is not named in CamelCase.
              Open

              class Text_MappedDiff extends Text_Diff
              {
                  /**
                   * Computes a diff between sequences of strings.
                   *
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseClassName

              Since: 0.2

              It is considered best practice to use the CamelCase notation to name classes.

              Example

              class class_name {
              }

              Source

              The class Text_Diff_Op_add is not named in CamelCase.
              Open

              class Text_Diff_Op_add extends Text_Diff_Op
              {
                  /**
                   * Text_Diff_Op_add constructor.
                   * @param $lines
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseClassName

              Since: 0.2

              It is considered best practice to use the CamelCase notation to name classes.

              Example

              class class_name {
              }

              Source

              The parameter $mapped_to_lines is not named in camelCase.
              Open

                  public function __construct($from_lines, $to_lines, $mapped_from_lines, $mapped_to_lines)
                  {
                      assert(count($from_lines) == count($mapped_from_lines));
                      assert(count($to_lines) == count($mapped_to_lines));
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseParameterName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name parameters.

              Example

              class ClassName {
                  public function doSomething($user_name) {
                  }
              }

              Source

              The class Text_Diff_Op is not named in CamelCase.
              Open

              class Text_Diff_Op
              {
                  public $orig;
                  public $final;
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseClassName

              Since: 0.2

              It is considered best practice to use the CamelCase notation to name classes.

              Example

              class class_name {
              }

              Source

              The class Text_Diff_Op_copy is not named in CamelCase.
              Open

              class Text_Diff_Op_copy extends Text_Diff_Op
              {
                  /**
                   * Text_Diff_Op_copy constructor.
                   * @param      $orig
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseClassName

              Since: 0.2

              It is considered best practice to use the CamelCase notation to name classes.

              Example

              class class_name {
              }

              Source

              The parameter $to_lines is not named in camelCase.
              Open

                  public function _check($from_lines, $to_lines)
                  {
                      if (serialize($from_lines) != serialize($this->getOriginal())) {
                          trigger_error("Reconstructed original doesn't match", E_USER_ERROR);
                      }
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseParameterName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name parameters.

              Example

              class ClassName {
                  public function doSomething($user_name) {
                  }
              }

              Source

              The class Text_Diff_Engine_xdiff is not named in CamelCase.
              Open

              class Text_Diff_Engine_xdiff
              {
                  /**
                   * @param $from_lines
                   * @param $to_lines
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseClassName

              Since: 0.2

              It is considered best practice to use the CamelCase notation to name classes.

              Example

              class class_name {
              }

              Source

              The parameter $to_lines is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      /* Convert the two input arrays into strings for xdiff processing. */
                      $from_string = implode("\n", $from_lines);
                      $to_string   = implode("\n", $to_lines);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseParameterName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name parameters.

              Example

              class ClassName {
                  public function doSomething($user_name) {
                  }
              }

              Source

              Avoid variables with short names like $i. Configured minimum length is 3.
              Open

                      $i = 0;
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              ShortVariable

              Since: 0.2

              Detects when a field, local, or parameter has a very short name.

              Example

              class Something {
                  private $q = 15; // VIOLATION - Field
                  public static function main( array $as ) { // VIOLATION - Formal
                      $r = 20 + $this->q; // VIOLATION - Local
                      for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
                          $r += $this->q;
                      }
                  }
              }

              Source https://phpmd.org/rules/naming.html#shortvariable

              Avoid variables with short names like $j. Configured minimum length is 3.
              Open

                      $j = 0;
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              ShortVariable

              Since: 0.2

              Detects when a field, local, or parameter has a very short name.

              Example

              class Something {
                  private $q = 15; // VIOLATION - Field
                  public static function main( array $as ) { // VIOLATION - Formal
                      $r = 20 + $this->q; // VIOLATION - Local
                      for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
                          $r += $this->q;
                      }
                  }
              }

              Source https://phpmd.org/rules/naming.html#shortvariable

              Avoid variables with short names like $yi. Configured minimum length is 3.
              Open

                      $xi = $yi = 0;
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              ShortVariable

              Since: 0.2

              Detects when a field, local, or parameter has a very short name.

              Example

              class Something {
                  private $q = 15; // VIOLATION - Field
                  public static function main( array $as ) { // VIOLATION - Formal
                      $r = 20 + $this->q; // VIOLATION - Local
                      for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
                          $r += $this->q;
                      }
                  }
              }

              Source https://phpmd.org/rules/naming.html#shortvariable

              The parameter $from_lines is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      /* Convert the two input arrays into strings for xdiff processing. */
                      $from_string = implode("\n", $from_lines);
                      $to_string   = implode("\n", $to_lines);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseParameterName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name parameters.

              Example

              class ClassName {
                  public function doSomething($user_name) {
                  }
              }

              Source

              Avoid variables with short names like $xi. Configured minimum length is 3.
              Open

                      $xi = $n_from;
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              ShortVariable

              Since: 0.2

              Detects when a field, local, or parameter has a very short name.

              Example

              class Something {
                  private $q = 15; // VIOLATION - Field
                  public static function main( array $as ) { // VIOLATION - Formal
                      $r = 20 + $this->q; // VIOLATION - Local
                      for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
                          $r += $this->q;
                      }
                  }
              }

              Source https://phpmd.org/rules/naming.html#shortvariable

              The parameter $mapped_from_lines is not named in camelCase.
              Open

                  public function __construct($from_lines, $to_lines, $mapped_from_lines, $mapped_to_lines)
                  {
                      assert(count($from_lines) == count($mapped_from_lines));
                      assert(count($to_lines) == count($mapped_to_lines));
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseParameterName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name parameters.

              Example

              class ClassName {
                  public function doSomething($user_name) {
                  }
              }

              Source

              Avoid variables with short names like $x1. Configured minimum length is 3.
              Open

                          $x1 = $xoff + (int)(($numer + ($xlim - $xoff) * $chunk) / $nchunks);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              ShortVariable

              Since: 0.2

              Detects when a field, local, or parameter has a very short name.

              Example

              class Something {
                  private $q = 15; // VIOLATION - Field
                  public static function main( array $as ) { // VIOLATION - Formal
                      $r = 20 + $this->q; // VIOLATION - Local
                      for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
                          $r += $this->q;
                      }
                  }
              }

              Source https://phpmd.org/rules/naming.html#shortvariable

              Avoid variables with short names like $x. Configured minimum length is 3.
              Open

                      $x     = $xoff;
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              ShortVariable

              Since: 0.2

              Detects when a field, local, or parameter has a very short name.

              Example

              class Something {
                  private $q = 15; // VIOLATION - Field
                  public static function main( array $as ) { // VIOLATION - Formal
                      $r = 20 + $this->q; // VIOLATION - Local
                      for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
                          $r += $this->q;
                      }
                  }
              }

              Source https://phpmd.org/rules/naming.html#shortvariable

              The class Text_Diff_Op_delete is not named in CamelCase.
              Open

              class Text_Diff_Op_delete extends Text_Diff_Op
              {
                  /**
                   * Text_Diff_Op_delete constructor.
                   * @param $lines
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseClassName

              Since: 0.2

              It is considered best practice to use the CamelCase notation to name classes.

              Example

              class class_name {
              }

              Source

              Avoid variables with short names like $xi. Configured minimum length is 3.
              Open

                      $xi = $yi = 0;
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              ShortVariable

              Since: 0.2

              Detects when a field, local, or parameter has a very short name.

              Example

              class Something {
                  private $q = 15; // VIOLATION - Field
                  public static function main( array $as ) { // VIOLATION - Formal
                      $r = 20 + $this->q; // VIOLATION - Local
                      for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
                          $r += $this->q;
                      }
                  }
              }

              Source https://phpmd.org/rules/naming.html#shortvariable

              The parameter $to_lines is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseParameterName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name parameters.

              Example

              class ClassName {
                  public function doSomething($user_name) {
                  }
              }

              Source

              The parameter $from_lines is not named in camelCase.
              Open

                  public function __construct($from_lines, $to_lines, $mapped_from_lines, $mapped_to_lines)
                  {
                      assert(count($from_lines) == count($mapped_from_lines));
                      assert(count($to_lines) == count($mapped_to_lines));
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseParameterName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name parameters.

              Example

              class ClassName {
                  public function doSomething($user_name) {
                  }
              }

              Source

              Avoid variables with short names like $yi. Configured minimum length is 3.
              Open

                      $yi = $n_to;
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              ShortVariable

              Since: 0.2

              Detects when a field, local, or parameter has a very short name.

              Example

              class Something {
                  private $q = 15; // VIOLATION - Field
                  public static function main( array $as ) { // VIOLATION - Formal
                      $r = 20 + $this->q; // VIOLATION - Local
                      for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
                          $r += $this->q;
                      }
                  }
              }

              Source https://phpmd.org/rules/naming.html#shortvariable

              The parameter $from_lines is not named in camelCase.
              Open

                  public function _check($from_lines, $to_lines)
                  {
                      if (serialize($from_lines) != serialize($this->getOriginal())) {
                          trigger_error("Reconstructed original doesn't match", E_USER_ERROR);
                      }
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseParameterName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name parameters.

              Example

              class ClassName {
                  public function doSomething($user_name) {
                  }
              }

              Source

              The parameter $to_lines is not named in camelCase.
              Open

                  public function __construct($from_lines, $to_lines, $mapped_from_lines, $mapped_to_lines)
                  {
                      assert(count($from_lines) == count($mapped_from_lines));
                      assert(count($to_lines) == count($mapped_to_lines));
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseParameterName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name parameters.

              Example

              class ClassName {
                  public function doSomething($user_name) {
                  }
              }

              Source

              The parameter $from_lines is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseParameterName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name parameters.

              Example

              class ClassName {
                  public function doSomething($user_name) {
                  }
              }

              Source

              The class Text_Diff_Engine_native is not named in CamelCase.
              Open

              class Text_Diff_Engine_native
              {
                  /**
                   * @param $from_lines
                   * @param $to_lines
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseClassName

              Since: 0.2

              It is considered best practice to use the CamelCase notation to name classes.

              Example

              class class_name {
              }

              Source

              Avoid variables with short names like $k. Configured minimum length is 3.
              Open

                                      $k = $this->_lcsPos($y);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              ShortVariable

              Since: 0.2

              Detects when a field, local, or parameter has a very short name.

              Example

              class Something {
                  private $q = 15; // VIOLATION - Field
                  public static function main( array $as ) { // VIOLATION - Formal
                      $r = 20 + $this->q; // VIOLATION - Local
                      for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
                          $r += $this->q;
                      }
                  }
              }

              Source https://phpmd.org/rules/naming.html#shortvariable

              The parameter $other_changed is not named in camelCase.
              Open

                  public function _shiftBoundaries($lines, &$changed, $other_changed)
                  {
                      $i = 0;
                      $j = 0;
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseParameterName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name parameters.

              Example

              class ClassName {
                  public function doSomething($user_name) {
                  }
              }

              Source

              Avoid variables with short names like $y1. Configured minimum length is 3.
              Open

                          $y1     = $ymid[$n] + 1;
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              ShortVariable

              Since: 0.2

              Detects when a field, local, or parameter has a very short name.

              Example

              class Something {
                  private $q = 15; // VIOLATION - Field
                  public static function main( array $as ) { // VIOLATION - Formal
                      $r = 20 + $this->q; // VIOLATION - Local
                      for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
                          $r += $this->q;
                      }
                  }
              }

              Source https://phpmd.org/rules/naming.html#shortvariable

              The class Text_Diff_Op_change is not named in CamelCase.
              Open

              class Text_Diff_Op_change extends Text_Diff_Op
              {
                  /**
                   * Text_Diff_Op_change constructor.
                   * @param $orig
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseClassName

              Since: 0.2

              It is considered best practice to use the CamelCase notation to name classes.

              Example

              class class_name {
              }

              Source

              Each class must be in a file by itself
              Open

              class Text_Diff_Engine_xdiff
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Each class must be in a file by itself
              Open

              class Text_Diff_Op_copy extends Text_Diff_Op
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Each class must be in a file by itself
              Open

              class Text_Diff_Op_change extends Text_Diff_Op
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Each class must be in a file by itself
              Open

              class Text_Diff_Op
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Each class must be in a file by itself
              Open

              class Text_MappedDiff extends Text_Diff
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Each class must be in a file by itself
              Open

              class Text_Diff_Op_delete extends Text_Diff_Op
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Each class must be in a file by itself
              Open

              class Text_Diff_Engine_native
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Each class must be in a file by itself
              Open

              class Text_Diff_Op_add extends Text_Diff_Op
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Method name "_trimNewlines" should not be prefixed with an underscore to indicate visibility
              Open

                  public function _trimNewlines(&$line, $key)
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Method name "_compareseq" should not be prefixed with an underscore to indicate visibility
              Open

                  public function _compareseq($xoff, $xlim, $yoff, $ylim)
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Property name "$_edits" should not be prefixed with an underscore to indicate visibility
              Open

                  public $_edits;
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Method name "_check" should not be prefixed with an underscore to indicate visibility
              Open

                  public function _check($from_lines, $to_lines)
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Method name "_lcsPos" should not be prefixed with an underscore to indicate visibility
              Open

                  public function _lcsPos($ypos)
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Method name "_diag" should not be prefixed with an underscore to indicate visibility
              Open

                  public function _diag($xoff, $xlim, $yoff, $ylim, $nchunks)
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Method name "_shiftBoundaries" should not be prefixed with an underscore to indicate visibility
              Open

                  public function _shiftBoundaries($lines, &$changed, $other_changed)
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Class name "Text_Diff_Op_change" is not in camel caps format
              Open

              class Text_Diff_Op_change extends Text_Diff_Op
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Class name "Text_Diff_Engine_xdiff" is not in camel caps format
              Open

              class Text_Diff_Engine_xdiff
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Class name "Text_MappedDiff" is not in camel caps format
              Open

              class Text_MappedDiff extends Text_Diff
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Class name "Text_Diff_Op_delete" is not in camel caps format
              Open

              class Text_Diff_Op_delete extends Text_Diff_Op
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Class name "Text_Diff" is not in camel caps format
              Open

              class Text_Diff
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Class name "Text_Diff_Op" is not in camel caps format
              Open

              class Text_Diff_Op
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Class name "Text_Diff_Engine_native" is not in camel caps format
              Open

              class Text_Diff_Engine_native
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Class name "Text_Diff_Op_copy" is not in camel caps format
              Open

              class Text_Diff_Op_copy extends Text_Diff_Op
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              Class name "Text_Diff_Op_add" is not in camel caps format
              Open

              class Text_Diff_Op_add extends Text_Diff_Op
              Severity: Minor
              Found in include/Text_Diff.php by phpcodesniffer

              The variable $to_lines is not named in camelCase.
              Open

                  public function __construct($from_lines, $to_lines)
                  {
                      array_walk($from_lines, array($this, '_trimNewlines'));
                      array_walk($to_lines, array($this, '_trimNewlines'));
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $from_lines is not named in camelCase.
              Open

                  public function __construct($from_lines, $to_lines)
                  {
                      array_walk($from_lines, array($this, '_trimNewlines'));
                      array_walk($to_lines, array($this, '_trimNewlines'));
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $from_lines is not named in camelCase.
              Open

                  public function __construct($from_lines, $to_lines)
                  {
                      array_walk($from_lines, array($this, '_trimNewlines'));
                      array_walk($to_lines, array($this, '_trimNewlines'));
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $to_lines is not named in camelCase.
              Open

                  public function __construct($from_lines, $to_lines)
                  {
                      array_walk($from_lines, array($this, '_trimNewlines'));
                      array_walk($to_lines, array($this, '_trimNewlines'));
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $from_lines is not named in camelCase.
              Open

                  public function _check($from_lines, $to_lines)
                  {
                      if (serialize($from_lines) != serialize($this->getOriginal())) {
                          trigger_error("Reconstructed original doesn't match", E_USER_ERROR);
                      }
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $to_lines is not named in camelCase.
              Open

                  public function __construct($from_lines, $to_lines, $mapped_from_lines, $mapped_to_lines)
                  {
                      assert(count($from_lines) == count($mapped_from_lines));
                      assert(count($to_lines) == count($mapped_to_lines));
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $mapped_to_lines is not named in camelCase.
              Open

                  public function __construct($from_lines, $to_lines, $mapped_from_lines, $mapped_to_lines)
                  {
                      assert(count($from_lines) == count($mapped_from_lines));
                      assert(count($to_lines) == count($mapped_to_lines));
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $from_lines is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $other_len is not named in camelCase.
              Open

                  public function _shiftBoundaries($lines, &$changed, $other_changed)
                  {
                      $i = 0;
                      $j = 0;
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $from_lines is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $from_lines is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $to_lines is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $n_from is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $other_changed is not named in camelCase.
              Open

                  public function _shiftBoundaries($lines, &$changed, $other_changed)
                  {
                      $i = 0;
                      $j = 0;
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $other_changed is not named in camelCase.
              Open

                  public function _shiftBoundaries($lines, &$changed, $other_changed)
                  {
                      $i = 0;
                      $j = 0;
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $to_lines is not named in camelCase.
              Open

                  public function _check($from_lines, $to_lines)
                  {
                      if (serialize($from_lines) != serialize($this->getOriginal())) {
                          trigger_error("Reconstructed original doesn't match", E_USER_ERROR);
                      }
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $from_lines is not named in camelCase.
              Open

                  public function _check($from_lines, $to_lines)
                  {
                      if (serialize($from_lines) != serialize($this->getOriginal())) {
                          trigger_error("Reconstructed original doesn't match", E_USER_ERROR);
                      }
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $from_lines is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      /* Convert the two input arrays into strings for xdiff processing. */
                      $from_string = implode("\n", $from_lines);
                      $to_string   = implode("\n", $to_lines);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $to_string is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      /* Convert the two input arrays into strings for xdiff processing. */
                      $from_string = implode("\n", $from_lines);
                      $to_string   = implode("\n", $to_lines);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $to_lines is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      /* Convert the two input arrays into strings for xdiff processing. */
                      $from_string = implode("\n", $from_lines);
                      $to_string   = implode("\n", $to_lines);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $n_from is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $other_changed is not named in camelCase.
              Open

                  public function _shiftBoundaries($lines, &$changed, $other_changed)
                  {
                      $i = 0;
                      $j = 0;
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $to_lines is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $other_len is not named in camelCase.
              Open

                  public function _shiftBoundaries($lines, &$changed, $other_changed)
                  {
                      $i = 0;
                      $j = 0;
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $from_lines is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $n_from is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $other_changed is not named in camelCase.
              Open

                  public function _shiftBoundaries($lines, &$changed, $other_changed)
                  {
                      $i = 0;
                      $j = 0;
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $other_len is not named in camelCase.
              Open

                  public function _shiftBoundaries($lines, &$changed, $other_changed)
                  {
                      $i = 0;
                      $j = 0;
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $mapped_from_lines is not named in camelCase.
              Open

                  public function __construct($from_lines, $to_lines, $mapped_from_lines, $mapped_to_lines)
                  {
                      assert(count($from_lines) == count($mapped_from_lines));
                      assert(count($to_lines) == count($mapped_to_lines));
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $n_to is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $from_lines is not named in camelCase.
              Open

                  public function __construct($from_lines, $to_lines, $mapped_from_lines, $mapped_to_lines)
                  {
                      assert(count($from_lines) == count($mapped_from_lines));
                      assert(count($to_lines) == count($mapped_to_lines));
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $from_lines is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $to_lines is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $n_from is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $to_lines is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $to_lines is not named in camelCase.
              Open

                  public function _check($from_lines, $to_lines)
                  {
                      if (serialize($from_lines) != serialize($this->getOriginal())) {
                          trigger_error("Reconstructed original doesn't match", E_USER_ERROR);
                      }
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $to_lines is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $from_lines is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $other_changed is not named in camelCase.
              Open

                  public function _shiftBoundaries($lines, &$changed, $other_changed)
                  {
                      $i = 0;
                      $j = 0;
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $other_len is not named in camelCase.
              Open

                  public function _shiftBoundaries($lines, &$changed, $other_changed)
                  {
                      $i = 0;
                      $j = 0;
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $mapped_from_lines is not named in camelCase.
              Open

                  public function __construct($from_lines, $to_lines, $mapped_from_lines, $mapped_to_lines)
                  {
                      assert(count($from_lines) == count($mapped_from_lines));
                      assert(count($to_lines) == count($mapped_to_lines));
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $n_to is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $n_from is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $other_changed is not named in camelCase.
              Open

                  public function _shiftBoundaries($lines, &$changed, $other_changed)
                  {
                      $i = 0;
                      $j = 0;
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $n_to is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $other_len is not named in camelCase.
              Open

                  public function _shiftBoundaries($lines, &$changed, $other_changed)
                  {
                      $i = 0;
                      $j = 0;
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $from_string is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      /* Convert the two input arrays into strings for xdiff processing. */
                      $from_string = implode("\n", $from_lines);
                      $to_string   = implode("\n", $to_lines);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $to_lines is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      /* Convert the two input arrays into strings for xdiff processing. */
                      $from_string = implode("\n", $from_lines);
                      $to_string   = implode("\n", $to_lines);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $to_lines is not named in camelCase.
              Open

                  public function __construct($from_lines, $to_lines, $mapped_from_lines, $mapped_to_lines)
                  {
                      assert(count($from_lines) == count($mapped_from_lines));
                      assert(count($to_lines) == count($mapped_to_lines));
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $n_to is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $n_to is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $n_to is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $n_from is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $n_from is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $from_lines is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $other_changed is not named in camelCase.
              Open

                  public function _shiftBoundaries($lines, &$changed, $other_changed)
                  {
                      $i = 0;
                      $j = 0;
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $to_lines is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $n_to is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $n_to is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $from_lines is not named in camelCase.
              Open

                  public function __construct($from_lines, $to_lines, $mapped_from_lines, $mapped_to_lines)
                  {
                      assert(count($from_lines) == count($mapped_from_lines));
                      assert(count($to_lines) == count($mapped_to_lines));
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $from_string is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      /* Convert the two input arrays into strings for xdiff processing. */
                      $from_string = implode("\n", $from_lines);
                      $to_string   = implode("\n", $to_lines);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $n_from is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $n_from is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $other_len is not named in camelCase.
              Open

                  public function _shiftBoundaries($lines, &$changed, $other_changed)
                  {
                      $i = 0;
                      $j = 0;
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $mapped_to_lines is not named in camelCase.
              Open

                  public function __construct($from_lines, $to_lines, $mapped_from_lines, $mapped_to_lines)
                  {
                      assert(count($from_lines) == count($mapped_from_lines));
                      assert(count($to_lines) == count($mapped_to_lines));
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $to_string is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      /* Convert the two input arrays into strings for xdiff processing. */
                      $from_string = implode("\n", $from_lines);
                      $to_string   = implode("\n", $to_lines);
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The variable $from_lines is not named in camelCase.
              Open

                  public function diff($from_lines, $to_lines)
                  {
                      $n_from = count($from_lines);
                      $n_to   = count($to_lines);
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseVariableName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name variables.

              Example

              class ClassName {
                  public function doSomething() {
                      $data_module = new DataModule();
                  }
              }

              Source

              The method _trimNewlines is not named in camelCase.
              Open

                  public function _trimNewlines(&$line, $key)
                  {
                      $line = str_replace(array("\n", "\r"), '', $line);
                  }
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseMethodName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name methods.

              Example

              class ClassName {
                  public function get_name() {
                  }
              }

              Source

              The method _check is not named in camelCase.
              Open

                  public function _check($from_lines, $to_lines)
                  {
                      if (serialize($from_lines) != serialize($this->getOriginal())) {
                          trigger_error("Reconstructed original doesn't match", E_USER_ERROR);
                      }
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseMethodName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name methods.

              Example

              class ClassName {
                  public function get_name() {
                  }
              }

              Source

              The method _lcsPos is not named in camelCase.
              Open

                  public function _lcsPos($ypos)
                  {
                      $end = $this->lcs;
                      if ($end == 0 || $ypos > $this->seq[$end]) {
                          $this->seq[++$this->lcs] = $ypos;
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseMethodName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name methods.

              Example

              class ClassName {
                  public function get_name() {
                  }
              }

              Source

              The method _diag is not named in camelCase.
              Open

                  public function _diag($xoff, $xlim, $yoff, $ylim, $nchunks)
                  {
                      $flip = false;
              
                      if ($xlim - $xoff > $ylim - $yoff) {
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseMethodName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name methods.

              Example

              class ClassName {
                  public function get_name() {
                  }
              }

              Source

              The method _compareseq is not named in camelCase.
              Open

                  public function _compareseq($xoff, $xlim, $yoff, $ylim)
                  {
                      /* Slide down the bottom initial diagonal. */
                      while ($xoff < $xlim && $yoff < $ylim && $this->xv[$xoff] == $this->yv[$yoff]) {
                          ++$xoff;
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseMethodName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name methods.

              Example

              class ClassName {
                  public function get_name() {
                  }
              }

              Source

              The method _shiftBoundaries is not named in camelCase.
              Open

                  public function _shiftBoundaries($lines, &$changed, $other_changed)
                  {
                      $i = 0;
                      $j = 0;
              
              
              Severity: Minor
              Found in include/Text_Diff.php by phpmd

              CamelCaseMethodName

              Since: 0.2

              It is considered best practice to use the camelCase notation to name methods.

              Example

              class ClassName {
                  public function get_name() {
                  }
              }

              Source

              There are no issues that match your filters.

              Category
              Status