diff --git a/core/src/main/java/nl/tudelft/ewi/auta/core/controller/SubmitAppController.java b/core/src/main/java/nl/tudelft/ewi/auta/core/controller/SubmitAppController.java
index 147f999704f5646226b2ce7fbc46ee0b7896935b..355df17889e103a7fb5160807620901d239efdcc 100644
--- a/core/src/main/java/nl/tudelft/ewi/auta/core/controller/SubmitAppController.java
+++ b/core/src/main/java/nl/tudelft/ewi/auta/core/controller/SubmitAppController.java
@@ -192,6 +192,11 @@ public class SubmitAppController extends ControllerBase
return ResponseEntity.created(this.generateSubmissionUri(aid, sid)).body(res);
}
+ /**
+ * Sends a finished report to Submit.
+ *
+ * @param event the event
+ */
@Override
public void onApplicationEvent(final ReportCreatedEvent event) {
final var sid = event.getSubmissionId();
@@ -217,6 +222,12 @@ public class SubmitAppController extends ControllerBase
this.generateAndSendFeedback(entityContainer, submitMetadata);
}
+ /**
+ * Generates reports for each access level and sends them to Submit.
+ *
+ * @param entityContainer the container for the analyzed entity
+ * @param submitMetadata metadata on where and how to send the feedback
+ */
private void generateAndSendFeedback(
final EntityContainer entityContainer, final SubmitAppMetadata submitMetadata
) {
@@ -241,6 +252,15 @@ public class SubmitAppController extends ControllerBase
}
}
+ /**
+ * Sends a report to Submit.
+ *
+ * @param url the URL to send the feedback to
+ * @param report the report to send
+ * @param visibleFor for whom the report should be visible
+ * @param submitMetadata metadata to be attached to the feedback
+ * @param score the final score, if any
+ */
private void sendFeedback(
final URL url,
final String report,
@@ -278,6 +298,13 @@ public class SubmitAppController extends ControllerBase
}
}
+ /**
+ * Sends the score matching the given verdict to Submit.
+ *
+ * @param url the URL to post the score to
+ * @param submitMetadata metadata to attach to the score
+ * @param verdict the verdict mapping to the score
+ */
private void sendScore(
final URL url,
final SubmitAppMetadata submitMetadata,