|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.atlassian.crowd.importer.importers.BambooImporter
public class BambooImporter
Specific Bamboo Hibernate/Atlassian-User implementation
| Field Summary | |
|---|---|
protected DirectoryManager |
directoryManager
|
protected org.springframework.jdbc.core.JdbcOperations |
jdbcTemplate
|
protected org.apache.log4j.Logger |
logger
|
protected PasswordHelper |
passwordHelper
|
| Constructor Summary | |
|---|---|
BambooImporter(DirectoryManager directoryManager,
PasswordHelper passwordHelper)
|
|
| Method Summary | |
|---|---|
java.util.Collection<GroupTemplate> |
findGroups(Configuration configuration)
Will locate and build a collection of GroupTemplate objects based on the passed in Configuration |
java.util.Collection<MembershipDTO> |
findGroupToGroupMemberships(Configuration configuration)
Will locate and build a collection of MembershipDTO objects which
represent membership relationships between groups and groups based on the passed in Configuration. |
java.util.List<UserTemplateWithCredentialAndAttributes> |
findUsers(Configuration configuration)
Will locate and build a collection of UserTemplate objects based on the passed in Configuration |
java.util.List<MembershipDTO> |
findUserToGroupMemberships(Configuration configuration)
Will locate and build a collection of MembershipDTO objects which
represent membership relationships between users and groups based on the passed in Configuration. |
java.lang.Class |
getConfigurationType()
The type of configuration being used for this Import. |
org.springframework.jdbc.core.RowMapper |
getGroupMapper(Configuration configuration)
|
org.springframework.jdbc.core.RowMapper |
getMembershipMapper()
|
java.lang.String |
getSelectAllGroupsSQL()
|
java.lang.String |
getSelectAllUserGroupMembershipsSQL()
|
java.lang.String |
getSelectAllUsersSQL()
|
org.springframework.jdbc.core.RowMapper |
getUserMapper(Configuration configuration,
PasswordHelper passwordGenerator)
|
protected Result |
importGroupMemberships(java.lang.Iterable<MembershipDTO> memberships,
Configuration configuration)
|
protected Result |
importGroups(java.util.Collection<GroupTemplate> groups,
Configuration configuration)
|
protected Result |
importUserMemberships(java.lang.Iterable<MembershipDTO> memberships,
Configuration configuration)
|
protected Result |
importUsers(java.util.Collection<UserTemplateWithCredentialAndAttributes> users,
Configuration configuration)
|
Result |
importUsersGroupsAndMemberships(Configuration configuration)
Responsible for the import of both users and groups into Crowd using the given Configuration |
void |
init(Configuration configuration)
Initialise anything required for the import process. |
java.util.Set<Directory> |
retrieveRemoteSourceDirectory(Configuration configuration)
The retrieve the set of remote source directories. |
void |
setJdbcTemplate(org.springframework.jdbc.core.JdbcOperations jdbcTemplate)
|
boolean |
supportsMultipleDirectories(Configuration configuration)
Some sources might be capable of handling more than one directory. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface com.atlassian.crowd.importer.importers.Importer |
|---|
importUsersGroupsAndMemberships, retrieveRemoteSourceDirectory, supportsMultipleDirectories |
| Field Detail |
|---|
protected org.springframework.jdbc.core.JdbcOperations jdbcTemplate
protected PasswordHelper passwordHelper
protected final org.apache.log4j.Logger logger
protected final DirectoryManager directoryManager
| Constructor Detail |
|---|
public BambooImporter(DirectoryManager directoryManager,
PasswordHelper passwordHelper)
| Method Detail |
|---|
public java.lang.String getSelectAllGroupsSQL()
public java.lang.String getSelectAllUsersSQL()
public java.lang.String getSelectAllUserGroupMembershipsSQL()
public org.springframework.jdbc.core.RowMapper getGroupMapper(Configuration configuration)
public org.springframework.jdbc.core.RowMapper getMembershipMapper()
public org.springframework.jdbc.core.RowMapper getUserMapper(Configuration configuration,
PasswordHelper passwordGenerator)
public java.util.Collection<GroupTemplate> findGroups(Configuration configuration)
configuration - the configuration that contains the directory to import the groups too
public java.util.List<MembershipDTO> findUserToGroupMemberships(Configuration configuration)
MembershipDTO objects which
represent membership relationships between users and groups based on the passed in Configuration.
configuration - the Importer Configuration
public java.util.Collection<MembershipDTO> findGroupToGroupMemberships(Configuration configuration)
throws ImporterException
MembershipDTO objects which
represent membership relationships between groups and groups based on the passed in Configuration.
configuration - the Importer Configuration
ImporterException - if there is an error finding group membershipspublic java.util.List<UserTemplateWithCredentialAndAttributes> findUsers(Configuration configuration)
configuration - the Importer Configuration
public java.lang.Class getConfigurationType()
Importer
getConfigurationType in interface Importerpublic void init(Configuration configuration)
Importer
init in interface Importerconfiguration - can contain any setup params such as database settings that need init'ingpublic void setJdbcTemplate(org.springframework.jdbc.core.JdbcOperations jdbcTemplate)
protected Result importGroups(java.util.Collection<GroupTemplate> groups,
Configuration configuration)
throws ImporterException
ImporterException
protected Result importUsers(java.util.Collection<UserTemplateWithCredentialAndAttributes> users,
Configuration configuration)
throws ImporterException
ImporterException
protected Result importUserMemberships(java.lang.Iterable<MembershipDTO> memberships,
Configuration configuration)
throws ImporterException
ImporterException
protected Result importGroupMemberships(java.lang.Iterable<MembershipDTO> memberships,
Configuration configuration)
throws ImporterException
ImporterException
public Result importUsersGroupsAndMemberships(Configuration configuration)
throws ImporterException
ImporterConfiguration
importUsersGroupsAndMemberships in interface Importerconfiguration - the Configuration, this could be a JDBC configuration or a CSVConfiguration
ImporterException - general exception if anything happened during the importpublic boolean supportsMultipleDirectories(Configuration configuration)
Importer
supportsMultipleDirectories in interface Importerconfiguration - the Importer Configuration
public java.util.Set<Directory> retrieveRemoteSourceDirectory(Configuration configuration)
Importer
retrieveRemoteSourceDirectory in interface Importerconfiguration - the import configuration.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||