Details

    • Type: Task
    • Status: Done
    • Priority: L3 - Default
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.2.0-alpha1, 2.2.0
    • Component/s: backend
    • Labels:
      None

      Description

      Context:
      We currently go through the whole report data structure, validate every field and then find the report evaluation command for the given structure. However, this results in a huge function mess that contains a lot redundant code and is prone to copy paste errors. Also it is really hard to walk through that function tree.

      AT:

      • it is much easier to perform validation for a new report

        Activity

        Hide
        kyrylo.zakurdaiev Kyrylo Zakurdaiev added a comment -

        Review hints:

        • to avoid code duplication, all the methods in the `ViewDtoCreator` class could be one method which would receive 3 parameters
        • typo in the ViewDto.java Line 42
        Show
        kyrylo.zakurdaiev Kyrylo Zakurdaiev added a comment - Review hints: to avoid code duplication, all the methods in the `ViewDtoCreator` class could be one method which would receive 3 parameters typo in the ViewDto.java Line 42
        Hide
        johannes.heinemann Johannes Heinemann added a comment -

        Regarding your hints:

        • You are right, that there is quite some code duplication, but having a method for each combination makes the calling code shorter. I think it's matter of taste and I decided to leave it like it is for now. If you have a strong opinion on that, we can also discuss it.
        • It corrected the typo.
        Show
        johannes.heinemann Johannes Heinemann added a comment - Regarding your hints: You are right, that there is quite some code duplication, but having a method for each combination makes the calling code shorter. I think it's matter of taste and I decided to leave it like it is for now. If you have a strong opinion on that, we can also discuss it. It corrected the typo.

          People

          • Assignee:
            Unassigned
            Reporter:
            johannes.heinemann Johannes Heinemann
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: