com.atlassian.jira.imports.project.mapper
Class UserMapper
java.lang.Object
com.atlassian.jira.imports.project.mapper.AbstractMapper
com.atlassian.jira.imports.project.mapper.UserMapper
- All Implemented Interfaces:
- ProjectImportIdMapper
@PublicApi
public class UserMapper
- extends AbstractMapper
Allows you to map Users.
We keep the whole ExternalUser information so we can create Users that don't exist.
- Since:
- v3.13
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
UserMapper
public UserMapper(UserUtil userUtil)
registerOldValue
public void registerOldValue(ExternalUser externalUser)
getExternalUser
public ExternalUser getExternalUser(String userKey)
getMappedId
public String getMappedId(String oldId)
- Description copied from interface:
ProjectImportIdMapper
- Retrieves a String that corresponds to the id in the target JIRA system, null if none has been mapped.
- Specified by:
getMappedId
in interface ProjectImportIdMapper
- Overrides:
getMappedId
in class AbstractMapper
- Parameters:
oldId
- identifies the mapping we are looking for.
- Returns:
- String that corresponds to the id in the target JIRA system, null if none has been mapped.
flagUserAsMandatory
public void flagUserAsMandatory(String oldUserKey)
flagUserAsInUse
public void flagUserAsInUse(String oldUserKey)
getUnmappedMandatoryUsers
public Collection<ExternalUser> getUnmappedMandatoryUsers()
getUnmappedMandatoryUsersWithNoRegisteredOldValue
public List<ExternalUser> getUnmappedMandatoryUsersWithNoRegisteredOldValue()
getUnmappedUsersInUseWithNoRegisteredOldValue
public List<ExternalUser> getUnmappedUsersInUseWithNoRegisteredOldValue()
getUnmappedUsersInUse
public Collection<ExternalUser> getUnmappedUsersInUse()
getUsersToAutoCreate
public Collection<ExternalUser> getUsersToAutoCreate()
- Returns a List of users that can be automatically created by the import.
This includes all optional and mandatory users that aren't in the current system, and the import file has the user details for.
Note that this method only makes sense if External User Management is off.
- Returns:
- a List of users that can be automatically created by the import.
getOptionalOldIds
public Collection<String> getOptionalOldIds()
userExists
public boolean userExists(String userKey)
getMappedUserKey
public String getMappedUserKey(String oldUserKey)
Copyright © 2002-2014 Atlassian. All Rights Reserved.