-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adds the interface "UserEvent" to allow re-usable generic code where …
…only the user data is important. This will e.g. allow re-using constraints on the user data fields for different event types as well as to allow a default duplicate preventer for streaming events (in a future commit). An interface is used instead of an abstract class to keep the inheritance limitations low. Fixes: SE-14230
- Loading branch information
1 parent
eb19a72
commit 198ac89
Showing
5 changed files
with
40 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
/* | ||
* Made with all the love in the world | ||
* by scireum in Remshalden, Germany | ||
* | ||
* Copyright by scireum GmbH | ||
* http://www.scireum.de - info@scireum.de | ||
*/ | ||
|
||
package sirius.biz.analytics.events; | ||
|
||
import sirius.db.mixing.Mapping; | ||
|
||
/** | ||
* May be implemented by an {@link Event} to provide access to the {@link UserData} of the current user. | ||
*/ | ||
public interface UserEvent { | ||
|
||
/** | ||
* Contains the user data of the event. | ||
*/ | ||
Mapping USER_DATA = Mapping.named("userData"); | ||
|
||
/** | ||
* Returns the user data of the event. | ||
* | ||
* @return the user data of the event | ||
*/ | ||
UserData getUserData(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters