com.centrasite.resourceaccess.importer
Interface Importer


public interface Importer

Used for re-creating security layer data on basis registry objects used for Resource Access assets representation. Registry objects order needed for RAM ino:security data recreation. By order is meant availability via JAXR queries. For example, when a Role is imported, the Importer will need to retrieve the jaxr:User object which is having the Role. 1. Users 2. Permissions 3. Groups 4. (last!) Roles


Method Summary
 java.util.Collection<javax.xml.registry.infomodel.RegistryObject> deleteUnreferencedUsers()
          Delete unreferenced users from organisation after group replacements.
 void executeImport(javax.xml.registry.infomodel.RegistryObject ro)
          Re-create security layer data for a single Resource Access asset.
 void importGroupUserRelationships(java.util.Collection<javax.xml.registry.infomodel.RegistryObject> users, java.util.Collection<javax.xml.registry.infomodel.RegistryObject> groups)
           
 void importGRUPRelationships(java.util.Collection<javax.xml.registry.infomodel.RegistryObject> permissions, java.util.Collection<javax.xml.registry.infomodel.RegistryObject> groups, java.util.Collection<javax.xml.registry.infomodel.RegistryObject> users, java.util.Collection<javax.xml.registry.infomodel.RegistryObject> roles)
          This method is used to establish Role-Permission, Group-Role, User-Role and Group-User relationships during import operation
 void setToRemoveGroupUsers(boolean toRemoveGroupUsers)
          Set if users to be removed during group import.
 

Method Detail

executeImport

void executeImport(javax.xml.registry.infomodel.RegistryObject ro)
                   throws javax.xml.registry.JAXRException,
                          com.softwareag.security.jaas.principals.SagGeneralSecurityException
Re-create security layer data for a single Resource Access asset. Accepted registry object types are Constants.OBJECT_TYPE_KEY_Group, Constants.OBJECT_TYPE_KEY_Role, Constants.OBJECT_TYPE_KEY_User, Constants.OBJECT_TYPE_KEY_Permission

Parameters:
ro - The registry object representing the Resource Access asset.
Throws:
javax.xml.registry.JAXRException - if a JAXR error occurs
com.softwareag.security.jaas.principals.SagGeneralSecurityException - if a security error occurs
java.lang.IllegalArgumentException - If the passed registry object is not of the supported types.

deleteUnreferencedUsers

java.util.Collection<javax.xml.registry.infomodel.RegistryObject> deleteUnreferencedUsers()
                                                                                          throws com.softwareag.security.jaas.principals.SagGeneralSecurityException,
                                                                                                 javax.xml.registry.JAXRException
Delete unreferenced users from organisation after group replacements.

Returns:
collection of failed users
Throws:
com.softwareag.security.jaas.principals.SagGeneralSecurityException
javax.xml.registry.JAXRException

setToRemoveGroupUsers

void setToRemoveGroupUsers(boolean toRemoveGroupUsers)
Set if users to be removed during group import.

Parameters:
toRemoveGroupUsers - true: remove users from group; false: keep all group users

importGRUPRelationships

void importGRUPRelationships(java.util.Collection<javax.xml.registry.infomodel.RegistryObject> permissions,
                             java.util.Collection<javax.xml.registry.infomodel.RegistryObject> groups,
                             java.util.Collection<javax.xml.registry.infomodel.RegistryObject> users,
                             java.util.Collection<javax.xml.registry.infomodel.RegistryObject> roles)
                             throws com.softwareag.security.jaas.principals.SagGeneralSecurityException,
                                    javax.xml.registry.JAXRException
This method is used to establish Role-Permission, Group-Role, User-Role and Group-User relationships during import operation

Throws:
com.softwareag.security.jaas.principals.SagGeneralSecurityException
javax.xml.registry.JAXRException

importGroupUserRelationships

void importGroupUserRelationships(java.util.Collection<javax.xml.registry.infomodel.RegistryObject> users,
                                  java.util.Collection<javax.xml.registry.infomodel.RegistryObject> groups)
                                  throws javax.xml.registry.JAXRException,
                                         com.softwareag.security.jaas.principals.SagGeneralSecurityException
Throws:
javax.xml.registry.JAXRException
com.softwareag.security.jaas.principals.SagGeneralSecurityException