cesardl/facultad-sample-app

View on GitHub

Showing 16 of 67 total issues

Method initComponents has 145 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    @PostConstruct
    private void initComponents() {

        javax.swing.ButtonGroup buttonGroup = new javax.swing.ButtonGroup();
        javax.swing.JPanel panel = new javax.swing.JPanel();
Severity: Major
Found in src/main/java/org/sanmarcux/view/JDialogStudent.java - About 5 hrs to fix

    Method initComponents has 101 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        @PostConstruct
        private void initComponents() {
    
            javax.swing.JPanel panel = new javax.swing.JPanel();
            javax.swing.JLabel labelCode = new javax.swing.JLabel();
    Severity: Major
    Found in src/main/java/org/sanmarcux/view/JDialogTeacher.java - About 4 hrs to fix

      Method initComponents has 91 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          @PostConstruct
          private void initComponents() {
              javax.swing.JPanel panel = new javax.swing.JPanel();
              tabbedPane = new javax.swing.JTabbedPane();
              javax.swing.JMenuBar menuBar = new javax.swing.JMenuBar();
      Severity: Major
      Found in src/main/java/org/sanmarcux/view/JFrameInit.java - About 3 hrs to fix

        File JDialogStudent.java has 296 lines of code (exceeds 250 allowed). Consider refactoring.
        Open

        /*
         * JDialogStudent.java
         *
         * Created on 12/07/2009, 05:13:31 PM
         */
        Severity: Minor
        Found in src/main/java/org/sanmarcux/view/JDialogStudent.java - About 3 hrs to fix

          Method initComponents has 56 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

              @PostConstruct
              private void initComponents() {
          
                  javax.swing.JScrollPane scrollPane = new javax.swing.JScrollPane();
                  table = new javax.swing.JTable();
          Severity: Major
          Found in src/main/java/org/sanmarcux/view/JPanelStudent.java - About 2 hrs to fix

            Method initComponents has 56 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                @PostConstruct
                private void initComponents() {
            
                    javax.swing.JScrollPane scrollPane = new javax.swing.JScrollPane();
                    table = new javax.swing.JTable();
            Severity: Major
            Found in src/main/java/org/sanmarcux/view/JPanelTeacher.java - About 2 hrs to fix

              Method validateData has 48 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  @Override
                  public boolean validateData() {
                      code = textFieldCode.getText().trim();
                      names = textFieldNames.getText().trim();
                      birthday = dateChooserBirthday.getDate();
              Severity: Minor
              Found in src/main/java/org/sanmarcux/view/JDialogTeacher.java - About 1 hr to fix

                Method initComponents has 46 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                    @PostConstruct
                    private void initComponents() {
                
                        javax.swing.JPanel panel = new javax.swing.JPanel();
                        javax.swing.JLabel labelImage = new javax.swing.JLabel();
                Severity: Minor
                Found in src/main/java/org/sanmarcux/view/JDialogAbout.java - About 1 hr to fix

                  Method validateData has 43 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                      @Override
                      public boolean validateData() {
                          code = textFieldCode.getText().trim();
                          names = textFieldNames.getText().trim();
                          birthday = dateChooserBirthday.getDate();
                  Severity: Minor
                  Found in src/main/java/org/sanmarcux/view/JDialogStudent.java - About 1 hr to fix

                    Method validateData has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
                    Open

                        @Override
                        public boolean validateData() {
                            code = textFieldCode.getText().trim();
                            names = textFieldNames.getText().trim();
                            birthday = dateChooserBirthday.getDate();
                    Severity: Minor
                    Found in src/main/java/org/sanmarcux/view/JDialogTeacher.java - 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

                    Method validateData has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
                    Open

                        @Override
                        public boolean validateData() {
                            code = textFieldCode.getText().trim();
                            names = textFieldNames.getText().trim();
                            birthday = dateChooserBirthday.getDate();
                    Severity: Minor
                    Found in src/main/java/org/sanmarcux/view/JDialogStudent.java - 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

                    Avoid too many return statements within this method.
                    Open

                                return false;
                    Severity: Major
                    Found in src/main/java/org/sanmarcux/view/JDialogTeacher.java - About 30 mins to fix

                      Avoid too many return statements within this method.
                      Open

                              return true;
                      Severity: Major
                      Found in src/main/java/org/sanmarcux/view/JDialogStudent.java - About 30 mins to fix

                        Avoid too many return statements within this method.
                        Open

                                return true;
                        Severity: Major
                        Found in src/main/java/org/sanmarcux/view/JDialogTeacher.java - About 30 mins to fix

                          Avoid too many return statements within this method.
                          Open

                                      return false;
                          Severity: Major
                          Found in src/main/java/org/sanmarcux/view/JDialogTeacher.java - About 30 mins to fix

                            Avoid too many return statements within this method.
                            Open

                                        return false;
                            Severity: Major
                            Found in src/main/java/org/sanmarcux/view/JDialogStudent.java - About 30 mins to fix
                              Severity
                              Category
                              Status
                              Source
                              Language