]> git.mxchange.org Git - jjobs-war.git/blob - src/java/org/mxchange/jjobs/beans/user/activity/JobsUserActivityWebApplicationController.java
updated jar(s)
[jjobs-war.git] / src / java / org / mxchange / jjobs / beans / user / activity / JobsUserActivityWebApplicationController.java
1 /*
2  * Copyright (C) 2016 Roland Haeder<rhaeder@cho-time.de>
3  *
4  * This program is free software: you can redistribute it and/or modify
5  * it under the terms of the GNU Affero General Public License as
6  * published by the Free Software Foundation, either version 3 of the
7  * License, or (at your option) any later version.
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12  * GNU Affero General Public License for more details.
13  *
14  * You should have received a copy of the GNU Affero General Public License
15  * along with this program.  If not, see <http://www.gnu.org/licenses/>.
16  */
17 package org.mxchange.jjobs.beans.user.activity;
18
19 import java.io.Serializable;
20 import java.util.List;
21 import javax.ejb.Local;
22 import org.mxchange.jusercore.events.confirmation.UserConfirmedAccountEvent;
23 import org.mxchange.jusercore.events.login.UserLoggedInEvent;
24 import org.mxchange.jusercore.events.registration.UserRegisteredEvent;
25 import org.mxchange.jusercore.events.resendlink.UserResendLinkAccountEvent;
26 import org.mxchange.jusercore.events.user.add.AdminAddedUserEvent;
27 import org.mxchange.jusercore.events.user.linked.AdminLinkedUserEvent;
28 import org.mxchange.jusercore.events.user.locked.AdminLockedUserEvent;
29 import org.mxchange.jusercore.events.user.password_change.UpdatedUserPasswordEvent;
30 import org.mxchange.jusercore.events.user.unlocked.AdminUnlockedUserEvent;
31 import org.mxchange.jusercore.events.user.update.AdminUpdatedUserDataEvent;
32 import org.mxchange.jusercore.events.user.update.UpdatedUserPersonalDataEvent;
33 import org.mxchange.jusercore.model.user.User;
34 import org.mxchange.jusercore.model.user.activity.LogableUserActivity;
35
36 /**
37  * A controller (bean) interface for user activity log
38  * <p>
39  * @author Roland Haeder<rhaeder@cho-time.de>
40  */
41 @Local
42 public interface JobsUserActivityWebApplicationController extends Serializable {
43
44         /**
45          * Event observer for newly added users by adminstrator
46          * <p>
47          * @param event Event being fired
48          */
49         void afterAdminAddedUserEvent (final AdminAddedUserEvent event);
50
51         /**
52          * Event observer for linked users with existing contact data
53          * <p>
54          * @param event Event being fired
55          */
56         void afterAdminLinkedUserEvent (final AdminLinkedUserEvent event);
57
58         /**
59          * Event observer for locked users
60          * <p>
61          * @param event Event being fired
62          */
63         void afterAdminLockedUserEvent (final AdminLockedUserEvent event);
64
65         /**
66          * Event observer for unlocked users
67          * <p>
68          * @param event Event being fired
69          */
70         void afterAdminUnlockedUserEvent (final AdminUnlockedUserEvent event);
71
72         /**
73          * Event observer for updated user data by administrator
74          * <p>
75          * @param event Event being updated
76          */
77         void afterAdminUpdatedUserDataEvent (final AdminUpdatedUserDataEvent event);
78
79         /**
80          * Event observer when user confirmed account.
81          * <p>
82          * @param event Event being fired
83          */
84         void afterUserConfirmedAccountEvent (final UserConfirmedAccountEvent event);
85
86         /**
87          * Method being call after user's password has been updated (and history
88          * entry has been created).
89          * <p>
90          * @param event Event being observed
91          */
92         void afterUserUpdatedPasswordEvent (final UpdatedUserPasswordEvent event);
93
94         /**
95          * Listens to fired event when user updated personal data
96          * <p>
97          * @param event Event being fired
98          */
99         void afterUserUpdatedPersonalDataEvent (final UpdatedUserPersonalDataEvent event);
100
101         /**
102          * Event observer for new user registrations
103          * <p>
104          * @param event Event being fired
105          */
106         void afterRegistrationEvent (final UserRegisteredEvent event);
107
108         /**
109          * Event observer for logged-in user
110          * <p>
111          * @param event Event being fired
112          */
113         void afterUserLoginEvent (final UserLoggedInEvent event);
114
115         /**
116          * Event observer for users resending their confirmation link
117          * <p>
118          * @param event Event being fired
119          */
120         void afterUserResendConfirmationLinkEvent (final UserResendLinkAccountEvent event);
121
122         /**
123          * Adds user activity entry with given type
124          * <p>
125          * @param user User instance
126          * @param activityType Activity type
127          */
128         void addUserActivity (final User user, final String activityType);
129
130         /**
131          * Adds user activity log with type and message
132          * <p>
133          * @param user User instance
134          * @param activityType Activity type
135          * @param message Activity message
136          */
137         void addUserActivity (final User user, final String activityType, final String message);
138
139         /**
140          * Returns a list of in beanHelper set user instance's activity log
141          * <p>
142          * @return List of user's activity log
143          */
144         List<LogableUserActivity> allCurrentUsersActivityLog();
145
146 }