Class UserActivationEventCommandUserManagement
java.lang.Object
com.atlassian.confluence.internal.api.impl.service.incrementalsync.MultiEventsCommand<T,UserManagementInSyncModel,UserJournalEntryTypes>
com.atlassian.confluence.internal.api.impl.service.incrementalsync.usermanagement.commands.UserManagementMultiEventsCommand<com.atlassian.crowd.event.user.UserEditedEvent>
com.atlassian.confluence.internal.api.impl.service.incrementalsync.usermanagement.commands.UserActivationEventCommandUserManagement
- All Implemented Interfaces:
Command<com.atlassian.crowd.event.user.UserEditedEvent,,UserManagementInSyncModel> CommandCreator<com.atlassian.crowd.event.user.UserEditedEvent,UserManagementInSyncModel>
public class UserActivationEventCommandUserManagement
extends UserManagementMultiEventsCommand<com.atlassian.crowd.event.user.UserEditedEvent>
-
Field Summary
Fields inherited from class com.atlassian.confluence.internal.api.impl.service.incrementalsync.usermanagement.commands.UserManagementMultiEventsCommand
commandSupportFields inherited from class com.atlassian.confluence.internal.api.impl.service.incrementalsync.MultiEventsCommand
logger, supportedEventEntryTypesMap -
Constructor Summary
ConstructorsConstructorDescriptionUserActivationEventCommandUserManagement(UserGroupCommandSupport commandSupport, PersonFactory personFactory) -
Method Summary
Modifier and TypeMethodDescriptionprotected Optional<JournalMessage>createMessage(com.atlassian.crowd.event.user.UserEditedEvent event) Creates anOptionalcontaining aJournalMessageto store in the DB.Map<Class<? extends com.atlassian.crowd.event.user.UserEditedEvent>,UserJournalEntryTypes> Provide a map of all supported eventsOptional<Command<com.atlassian.crowd.event.user.UserEditedEvent,UserManagementInSyncModel>> newCommand(JournalEntry journalEntry) Create new command from a journal entry.Optional<Command<com.atlassian.crowd.event.user.UserEditedEvent,UserManagementInSyncModel>> newCommand(com.atlassian.crowd.event.user.UserEditedEvent event) Create new command from an eventvoidprocessEvent(com.atlassian.crowd.event.user.UserEditedEvent event, Object... parameters) Processing an event then serialize as one or manyJournalEntryprocessJournalEntries(Collection<JournalEntry> journalEntries) DeserializeJournalEntryto JSON representable objectMethods inherited from class com.atlassian.confluence.internal.api.impl.service.incrementalsync.usermanagement.commands.UserManagementMultiEventsCommand
newCommand
-
Constructor Details
-
UserActivationEventCommandUserManagement
public UserActivationEventCommandUserManagement(UserGroupCommandSupport commandSupport, PersonFactory personFactory)
-
-
Method Details
-
getSupportedEventEntryTypesMap
public Map<Class<? extends com.atlassian.crowd.event.user.UserEditedEvent>,UserJournalEntryTypes> getSupportedEventEntryTypesMap()Description copied from class:MultiEventsCommandProvide a map of all supported events- Specified by:
getSupportedEventEntryTypesMapin classMultiEventsCommand<com.atlassian.crowd.event.user.UserEditedEvent,UserManagementInSyncModel, UserJournalEntryTypes> - Returns:
-
createMessage
protected Optional<JournalMessage> createMessage(com.atlassian.crowd.event.user.UserEditedEvent event) Description copied from class:UserManagementMultiEventsCommandCreates anOptionalcontaining aJournalMessageto store in the DB.- Specified by:
createMessagein classUserManagementMultiEventsCommand<com.atlassian.crowd.event.user.UserEditedEvent>- Parameters:
event- the event to process- Returns:
- an
Optionalcontaining theJournalMessage, orOptional.empty()if we don't want to store the value
-
processJournalEntries
public Collection<UserManagementInSyncModel> processJournalEntries(Collection<JournalEntry> journalEntries) Description copied from interface:CommandDeserializeJournalEntryto JSON representable object- Returns:
-
processEvent
public void processEvent(com.atlassian.crowd.event.user.UserEditedEvent event, Object... parameters) Description copied from interface:CommandProcessing an event then serialize as one or manyJournalEntry- Specified by:
processEventin interfaceCommand<com.atlassian.crowd.event.user.UserEditedEvent,UserManagementInSyncModel> - Overrides:
processEventin classUserManagementMultiEventsCommand<com.atlassian.crowd.event.user.UserEditedEvent>
-
newCommand
public Optional<Command<com.atlassian.crowd.event.user.UserEditedEvent,UserManagementInSyncModel>> newCommand(com.atlassian.crowd.event.user.UserEditedEvent event) Description copied from interface:CommandCreatorCreate new command from an event- Returns:
-
newCommand
public Optional<Command<com.atlassian.crowd.event.user.UserEditedEvent,UserManagementInSyncModel>> newCommand(JournalEntry journalEntry) Description copied from interface:CommandCreatorCreate new command from a journal entry. Concrete class should only return newCommandif the journalEntry is suitable for thatCommand- Returns:
-