ArtifactForms/MeshLibCore

View on GitHub
src/main/java/math/Vector3f.java

Summary

Maintainability
F
3 days
Test Coverage

Vector3f has 78 methods (exceeds 20 allowed). Consider refactoring.
Open

public class Vector3f {

  public static final Vector3f BACK = new Vector3f(0, 0, -1);

  public static final Vector3f DOWN = new Vector3f(0, -1, 0);
Severity: Major
Found in src/main/java/math/Vector3f.java - About 1 day to fix

    File Vector3f.java has 444 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    package math;
    
    public class Vector3f {
    
      public static final Vector3f BACK = new Vector3f(0, 0, -1);
    Severity: Minor
    Found in src/main/java/math/Vector3f.java - About 6 hrs to fix

      Avoid too many return statements within this method.
      Open

          return true;
      Severity: Major
      Found in src/main/java/math/Vector3f.java - About 30 mins to fix

        Avoid too many return statements within this method.
        Open

            if (Float.floatToIntBits(z) != Float.floatToIntBits(other.z)) return false;
        Severity: Major
        Found in src/main/java/math/Vector3f.java - About 30 mins to fix

          Avoid too many return statements within this method.
          Open

              if (Float.floatToIntBits(y) != Float.floatToIntBits(other.y)) return false;
          Severity: Major
          Found in src/main/java/math/Vector3f.java - About 30 mins to fix

            Method equals has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
            Open

              @Override
              public boolean equals(Object obj) {
                if (this == obj) return true;
                if (obj == null) return false;
                if (getClass() != obj.getClass()) return false;
            Severity: Minor
            Found in src/main/java/math/Vector3f.java - 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

            Similar blocks of code found in 2 locations. Consider refactoring.
            Open

              public Vector3f maxLocal(Vector3f a, Vector3f b) {
                x = Math.max(a.x, b.x);
                y = Math.max(a.y, b.y);
                z = Math.max(a.z, b.z);
                return this;
            Severity: Minor
            Found in src/main/java/math/Vector3f.java and 1 other location - About 55 mins to fix
            src/main/java/math/Vector3f.java on lines 388..393

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 63.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 2 locations. Consider refactoring.
            Open

              public Vector3f minLocal(Vector3f a, Vector3f b) {
                x = Math.min(a.x, b.x);
                y = Math.min(a.y, b.y);
                z = Math.min(a.z, b.z);
                return this;
            Severity: Minor
            Found in src/main/java/math/Vector3f.java and 1 other location - About 55 mins to fix
            src/main/java/math/Vector3f.java on lines 406..411

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 63.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 2 locations. Consider refactoring.
            Open

              public Vector3f maxLocal(Vector3f v) {
                x = Math.max(x, v.x);
                y = Math.max(y, v.y);
                z = Math.max(z, v.z);
                return this;
            Severity: Minor
            Found in src/main/java/math/Vector3f.java and 1 other location - About 45 mins to fix
            src/main/java/math/Vector3f.java on lines 381..386

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 56.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 2 locations. Consider refactoring.
            Open

              public Vector3f minLocal(Vector3f v) {
                x = Math.min(x, v.x);
                y = Math.min(y, v.y);
                z = Math.min(z, v.z);
                return this;
            Severity: Minor
            Found in src/main/java/math/Vector3f.java and 1 other location - About 45 mins to fix
            src/main/java/math/Vector3f.java on lines 399..404

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 56.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 3 locations. Consider refactoring.
            Open

                if (changeAmnt == 1) {
                  this.x = finalVec.x;
                  this.y = finalVec.y;
                  this.z = finalVec.z;
                  return this;
            Severity: Major
            Found in src/main/java/math/Vector3f.java and 2 other locations - About 40 mins to fix
            src/main/java/math/Vector3f.java on lines 424..429
            src/main/java/math/Vector3f.java on lines 437..442

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 50.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 3 locations. Consider refactoring.
            Open

                if (changeAmnt == 0) {
                  this.x = beginVec.x;
                  this.y = beginVec.y;
                  this.z = beginVec.z;
                  return this;
            Severity: Major
            Found in src/main/java/math/Vector3f.java and 2 other locations - About 40 mins to fix
            src/main/java/math/Vector3f.java on lines 424..429
            src/main/java/math/Vector3f.java on lines 443..448

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 50.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 3 locations. Consider refactoring.
            Open

                if (changeAmnt == 1) {
                  this.x = finalVec.x;
                  this.y = finalVec.y;
                  this.z = finalVec.z;
                  return this;
            Severity: Major
            Found in src/main/java/math/Vector3f.java and 2 other locations - About 40 mins to fix
            src/main/java/math/Vector3f.java on lines 437..442
            src/main/java/math/Vector3f.java on lines 443..448

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 50.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 6 locations. Consider refactoring.
            Open

                float z0 = m.values[6] * x + m.values[7] * y + m.values[8] * z;
            Severity: Major
            Found in src/main/java/math/Vector3f.java and 5 other locations - About 35 mins to fix
            src/main/java/math/Vector3f.java on lines 336..336
            src/main/java/math/Vector3f.java on lines 337..337
            src/main/java/math/Vector3f.java on lines 343..343
            src/main/java/math/Vector3f.java on lines 344..344
            src/main/java/math/Vector3f.java on lines 345..345

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 46.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 6 locations. Consider refactoring.
            Open

                float y0 = m.values[3] * x + m.values[4] * y + m.values[5] * z;
            Severity: Major
            Found in src/main/java/math/Vector3f.java and 5 other locations - About 35 mins to fix
            src/main/java/math/Vector3f.java on lines 336..336
            src/main/java/math/Vector3f.java on lines 337..337
            src/main/java/math/Vector3f.java on lines 338..338
            src/main/java/math/Vector3f.java on lines 343..343
            src/main/java/math/Vector3f.java on lines 345..345

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 46.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 6 locations. Consider refactoring.
            Open

                float y0 = m.values[3] * x + m.values[4] * y + m.values[5] * z;
            Severity: Major
            Found in src/main/java/math/Vector3f.java and 5 other locations - About 35 mins to fix
            src/main/java/math/Vector3f.java on lines 336..336
            src/main/java/math/Vector3f.java on lines 338..338
            src/main/java/math/Vector3f.java on lines 343..343
            src/main/java/math/Vector3f.java on lines 344..344
            src/main/java/math/Vector3f.java on lines 345..345

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 46.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 6 locations. Consider refactoring.
            Open

                float x0 = m.values[0] * x + m.values[1] * y + m.values[2] * z;
            Severity: Major
            Found in src/main/java/math/Vector3f.java and 5 other locations - About 35 mins to fix
            src/main/java/math/Vector3f.java on lines 336..336
            src/main/java/math/Vector3f.java on lines 337..337
            src/main/java/math/Vector3f.java on lines 338..338
            src/main/java/math/Vector3f.java on lines 344..344
            src/main/java/math/Vector3f.java on lines 345..345

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 46.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 6 locations. Consider refactoring.
            Open

                float x0 = m.values[0] * x + m.values[1] * y + m.values[2] * z;
            Severity: Major
            Found in src/main/java/math/Vector3f.java and 5 other locations - About 35 mins to fix
            src/main/java/math/Vector3f.java on lines 337..337
            src/main/java/math/Vector3f.java on lines 338..338
            src/main/java/math/Vector3f.java on lines 343..343
            src/main/java/math/Vector3f.java on lines 344..344
            src/main/java/math/Vector3f.java on lines 345..345

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 46.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 6 locations. Consider refactoring.
            Open

                float z0 = m.values[6] * x + m.values[7] * y + m.values[8] * z;
            Severity: Major
            Found in src/main/java/math/Vector3f.java and 5 other locations - About 35 mins to fix
            src/main/java/math/Vector3f.java on lines 336..336
            src/main/java/math/Vector3f.java on lines 337..337
            src/main/java/math/Vector3f.java on lines 338..338
            src/main/java/math/Vector3f.java on lines 343..343
            src/main/java/math/Vector3f.java on lines 344..344

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 46.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 5 locations. Consider refactoring.
            Open

              public Vector3f set(float x, float y, float z) {
                this.x = x;
                this.y = y;
                this.z = z;
                return this;
            Severity: Major
            Found in src/main/java/math/Vector3f.java and 4 other locations - About 30 mins to fix
            src/main/java/math/Vector3f.java on lines 225..230
            src/main/java/math/Vector3f.java on lines 252..257
            src/main/java/math/Vector3f.java on lines 279..284
            src/main/java/math/Vector3f.java on lines 306..311

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 40.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 5 locations. Consider refactoring.
            Open

              public Vector3f subtractLocal(float x, float y, float z) {
                this.x -= x;
                this.y -= y;
                this.z -= z;
                return this;
            Severity: Major
            Found in src/main/java/math/Vector3f.java and 4 other locations - About 30 mins to fix
            src/main/java/math/Vector3f.java on lines 225..230
            src/main/java/math/Vector3f.java on lines 279..284
            src/main/java/math/Vector3f.java on lines 306..311
            src/main/java/math/Vector3f.java on lines 467..472

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 40.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 5 locations. Consider refactoring.
            Open

              public Vector3f multLocal(float x, float y, float z) {
                this.x *= x;
                this.y *= y;
                this.z *= z;
                return this;
            Severity: Major
            Found in src/main/java/math/Vector3f.java and 4 other locations - About 30 mins to fix
            src/main/java/math/Vector3f.java on lines 225..230
            src/main/java/math/Vector3f.java on lines 252..257
            src/main/java/math/Vector3f.java on lines 306..311
            src/main/java/math/Vector3f.java on lines 467..472

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 40.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 5 locations. Consider refactoring.
            Open

              public Vector3f addLocal(float x, float y, float z) {
                this.x += x;
                this.y += y;
                this.z += z;
                return this;
            Severity: Major
            Found in src/main/java/math/Vector3f.java and 4 other locations - About 30 mins to fix
            src/main/java/math/Vector3f.java on lines 252..257
            src/main/java/math/Vector3f.java on lines 279..284
            src/main/java/math/Vector3f.java on lines 306..311
            src/main/java/math/Vector3f.java on lines 467..472

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 40.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 5 locations. Consider refactoring.
            Open

              public Vector3f divideLocal(float x, float y, float z) {
                this.x /= x;
                this.y /= y;
                this.z /= z;
                return this;
            Severity: Major
            Found in src/main/java/math/Vector3f.java and 4 other locations - About 30 mins to fix
            src/main/java/math/Vector3f.java on lines 225..230
            src/main/java/math/Vector3f.java on lines 252..257
            src/main/java/math/Vector3f.java on lines 279..284
            src/main/java/math/Vector3f.java on lines 467..472

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 40.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            There are no issues that match your filters.

            Category
            Status