com.atlassian.crowd.importer.importers
Class ConfluenceImporter

java.lang.Object
  extended by com.atlassian.crowd.importer.importers.ConfluenceImporter
All Implemented Interfaces:
Importer

public class ConfluenceImporter
extends java.lang.Object
implements Importer

This class handles the delegation of the import of Confluence Groups, Users and their memberships into Crowd.


Constructor Summary
ConfluenceImporter(DirectoryManager directoryManager, PasswordHelper passwordHelper)
           
 
Method Summary
 java.util.Collection<GroupMembership> findGroupMemberships(Configuration configuration)
          Will locate and build a collection of GroupMembership objects based on the passed in Configuration
 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<UserTemplateWithCredentialAndAttributes> findUsers(Configuration configuration)
          Will locate and build a collection of UserTemplate objects based on the passed in Configuration
 java.lang.Class getConfigurationType()
          The type of configuration being used for this Import.
 Result importUsersGroupsAndMemberships(Configuration configuration)
          This method will handle the importing of Users, Groups and Memberships from Confluence.
 void init(Configuration configuration)
          Initialise anything required for the import process.
 void setJdbcTemplate(JdbcConfiguration configuration)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ConfluenceImporter

public ConfluenceImporter(DirectoryManager directoryManager,
                          PasswordHelper passwordHelper)
Method Detail

importUsersGroupsAndMemberships

public Result importUsersGroupsAndMemberships(Configuration configuration)
                                       throws ImporterException
This method will handle the importing of Users, Groups and Memberships from Confluence.

Specified by:
importUsersGroupsAndMemberships in interface Importer
Parameters:
configuration - the configuration required for the import
Returns:
success or failure for the import.
Throws:
ImporterException - general exception if anything happened during the import

findGroupMemberships

public java.util.Collection<GroupMembership> findGroupMemberships(Configuration configuration)
                                                           throws ImporterException
Description copied from interface: Importer
Will locate and build a collection of GroupMembership objects based on the passed in Configuration

Specified by:
findGroupMemberships in interface Importer
Parameters:
configuration - the Importer Configuration
Returns:
a collection of GroupMemberships to be imported or Collections.EMPTY_LIST
Throws:
ImporterException - if there is an error finding group memberships

findGroups

public java.util.Collection<GroupTemplate> findGroups(Configuration configuration)
                                               throws ImporterException
Description copied from interface: Importer
Will locate and build a collection of GroupTemplate objects based on the passed in Configuration

Specified by:
findGroups in interface Importer
Parameters:
configuration - the Importer Configuration
Returns:
a collection of GroupTemplates to be imported or Collections.EMPTY_LIST
Throws:
ImporterException - if there is an error finding the groups

findUsers

public java.util.Collection<UserTemplateWithCredentialAndAttributes> findUsers(Configuration configuration)
                                                                        throws ImporterException
Description copied from interface: Importer
Will locate and build a collection of UserTemplate objects based on the passed in Configuration

Specified by:
findUsers in interface Importer
Parameters:
configuration - the Importer Configuration
Returns:
a collection of UserTemplates to be imported or Collections.EMPTY_LIST
Throws:
ImporterException - if there is an error finding the users

init

public void init(Configuration configuration)
Description copied from interface: Importer
Initialise anything required for the import process.

Specified by:
init in interface Importer
Parameters:
configuration - can contain any setup params such as database settings that need init'ing

getConfigurationType

public java.lang.Class getConfigurationType()
Description copied from interface: Importer
The type of configuration being used for this Import.

Specified by:
getConfigurationType in interface Importer
Returns:
Class that should be a subclass of Configuration

setJdbcTemplate

public void setJdbcTemplate(JdbcConfiguration configuration)


Copyright © 2010 Atlassian. All Rights Reserved.