Search in sources :

Example 31 with AMException

use of com.iplanet.am.sdk.AMException in project OpenAM by OpenRock.

the class ComplianceServicesImpl method verifyAndDeleteObject.

public void verifyAndDeleteObject(SSOToken token, String profileDN) throws AMException {
    try {
        Object[] objs = { token.getTokenID().toString(), profileDN };
        client.send(client.encodeMessage("verifyAndDeleteObject", objs), sessionCookies.getLBCookie(token.getTokenID().toString()), null);
    } catch (AMRemoteException amrex) {
        debug.error("ComplianceServicesImpl.verifyAndDeleteObject()- " + "encountered exception=", amrex);
        throw RemoteServicesImpl.convertException(amrex);
    } catch (RemoteException rex) {
        debug.error("ComplianceServicesImpl.verifyAndDeleteObject()- " + "encountered exception=", rex);
        throw new AMException(AMSDKBundle.getString("1000"), "1000");
    } catch (Exception ex) {
        debug.error("ComplianceServicesImpl.verifyAndDeleteObject()- " + "encountered exception=", ex);
        throw new AMException(AMSDKBundle.getString("1000"), "1000");
    }
}
Also used : AMException(com.iplanet.am.sdk.AMException) RemoteException(java.rmi.RemoteException) AMException(com.iplanet.am.sdk.AMException) SSOException(com.iplanet.sso.SSOException) RemoteException(java.rmi.RemoteException)

Example 32 with AMException

use of com.iplanet.am.sdk.AMException in project OpenAM by OpenRock.

the class DirectoryManagerImpl method setAttributes.

public void setAttributes(String token, String entryDN, int objectType, Map stringAttributes, Map byteAttributes, boolean isAdd) throws AMRemoteException, SSOException, RemoteException {
    initialize();
    try {
        SSOToken ssoToken = getSSOToken(token);
        dsServices.setAttributes(ssoToken, entryDN, objectType, stringAttributes, byteAttributes, isAdd);
    } catch (AMException amex) {
        if (debug.messageEnabled()) {
            debug.message("DirectoryManagerImpl.setAttributes." + " Caught Exception: " + amex);
        }
        throw convertException(amex);
    }
}
Also used : SSOToken(com.iplanet.sso.SSOToken) AMException(com.iplanet.am.sdk.AMException)

Example 33 with AMException

use of com.iplanet.am.sdk.AMException in project OpenAM by OpenRock.

the class DirectoryManagerImpl method removeEntry.

public void removeEntry(String token, String entryDN, int objectType, boolean recursive, boolean softDelete) throws AMRemoteException, SSOException, RemoteException {
    initialize();
    try {
        SSOToken ssoToken = getSSOToken(token);
        dsServices.removeEntry(ssoToken, entryDN, objectType, recursive, softDelete);
    } catch (AMException amex) {
        if (debug.messageEnabled()) {
            debug.message("DirectoryManagerImpl.removeEntry." + " Caught Exception: " + amex);
        }
        throw convertException(amex);
    }
}
Also used : SSOToken(com.iplanet.sso.SSOToken) AMException(com.iplanet.am.sdk.AMException)

Example 34 with AMException

use of com.iplanet.am.sdk.AMException in project OpenAM by OpenRock.

the class DirectoryManagerImpl method createEntry.

public void createEntry(String token, String entryName, int objectType, String parentDN, Map attributes) throws AMRemoteException, SSOException, RemoteException {
    initialize();
    try {
        SSOToken ssoToken = getSSOToken(token);
        dsServices.createEntry(ssoToken, entryName, objectType, parentDN, attributes);
    } catch (AMException e) {
        if (debug.messageEnabled()) {
            debug.message("DirectoryManagerImpl.createEntry." + " Caught Exception: " + e);
        }
        throw convertException(e);
    }
}
Also used : SSOToken(com.iplanet.sso.SSOToken) AMException(com.iplanet.am.sdk.AMException)

Example 35 with AMException

use of com.iplanet.am.sdk.AMException in project OpenAM by OpenRock.

the class DirectoryManagerImpl method changePassword.

public void changePassword(String token, String entryDN, String attrName, String oldPassword, String newPassword) throws AMRemoteException, SSOException, RemoteException {
    initialize();
    try {
        SSOToken ssoToken = getSSOToken(token);
        dsServices.changePassword(ssoToken, entryDN, attrName, oldPassword, newPassword);
    } catch (AMException amex) {
        if (debug.messageEnabled()) {
            debug.message("DirectoryManagerImpl.setAttributes." + " Caught Exception: " + amex);
        }
        throw convertException(amex);
    }
}
Also used : SSOToken(com.iplanet.sso.SSOToken) AMException(com.iplanet.am.sdk.AMException)

Aggregations

AMException (com.iplanet.am.sdk.AMException)127 SSOException (com.iplanet.sso.SSOException)56 Set (java.util.Set)35 AMEntryExistsException (com.iplanet.am.sdk.AMEntryExistsException)34 Guid (com.iplanet.ums.Guid)33 UMSException (com.iplanet.ums.UMSException)33 Map (java.util.Map)33 AMEventManagerException (com.iplanet.am.sdk.AMEventManagerException)32 RemoteException (java.rmi.RemoteException)31 AttrSet (com.iplanet.services.ldap.AttrSet)28 HashSet (java.util.HashSet)28 HashMap (java.util.HashMap)26 Iterator (java.util.Iterator)22 PersistentObject (com.iplanet.ums.PersistentObject)20 SSOToken (com.iplanet.sso.SSOToken)14 EntryNotFoundException (com.iplanet.ums.EntryNotFoundException)13 AMHashMap (com.iplanet.am.sdk.AMHashMap)12 AccessRightsException (com.iplanet.ums.AccessRightsException)12 SMSException (com.sun.identity.sm.SMSException)12 DN (org.forgerock.opendj.ldap.DN)12