Bläddra i källkod

Renamed to ApplicationEvents to emphasize application layer home.

peter_backlund 17 år sedan
förälder
incheckning
430392d4cc

dddsample/src/main/java/se/citerus/dddsample/application/SystemEvents.java → dddsample/src/main/java/se/citerus/dddsample/application/ApplicationEvents.java Visa fil

@@ -11,7 +11,7 @@ import se.citerus.dddsample.domain.model.handling.HandlingEvent;
11 11
  * It may be implemented synchronously or asynchronously, using
12 12
  * for example JMS.
13 13
  */
14
-public interface SystemEvents {
14
+public interface ApplicationEvents {
15 15
 
16 16
   /**
17 17
    * A cargo has been handled.
@@ -20,12 +20,33 @@ public interface SystemEvents {
20 20
    */
21 21
   void cargoWasHandled(HandlingEvent event);
22 22
 
23
+  /**
24
+   * A cargo has been misdirected.
25
+   *
26
+   * @param cargo cargo
27
+   */
23 28
   void cargoWasMisdirected(Cargo cargo);
24 29
 
30
+  /**
31
+   * A cargo has arrived at its final destination.
32
+   *
33
+   * @param cargo cargo
34
+   */
25 35
   void cargoHasArrived(Cargo cargo);
26 36
 
27
-  void rejectHandlingEventRegistrationAttempt(HandlingEventRegistrationAttempt attempt, CannotCreateHandlingEventException problem);
28
-
37
+  /**
38
+   * A handling event regitration attempt is received.
39
+   *
40
+   * @param attempt handling event registration attempt
41
+   */
29 42
   void receivedHandlingEventRegistrationAttempt(HandlingEventRegistrationAttempt attempt);
30 43
 
44
+  /**
45
+   * A handling event regitration attempt is rejected for a certain reason.
46
+   *
47
+   * @param attempt handling event registration attempt
48
+   * @param cause cause of rejection
49
+   */
50
+  void rejectedHandlingEventRegistrationAttempt(HandlingEventRegistrationAttempt attempt, CannotCreateHandlingEventException cause);
51
+
31 52
 }