Author: bdaw
Date: 2008-09-20 16:08:05 -0400 (Sat, 20 Sep 2008)
New Revision: 99
Added:
trunk/identity-api/src/main/java/org/jboss/identity/api2/event/
trunk/identity-api/src/main/java/org/jboss/identity/api2/event/IdentityEvent.java
trunk/identity-api/src/main/java/org/jboss/identity/api2/event/IdentityEventBroadcaster.java
trunk/identity-api/src/main/java/org/jboss/identity/api2/event/IdentityEventEmitter.java
trunk/identity-api/src/main/java/org/jboss/identity/api2/event/IdentityEventListener.java
trunk/identity-api/src/main/java/org/jboss/identity/api2/exception/
trunk/identity-api/src/main/java/org/jboss/identity/api2/exception/PersistenceManagerNotFoundException.java
trunk/identity-api/src/main/java/org/jboss/identity/api2/exception/SessionNotOpenException.java
Modified:
trunk/identity-api/src/main/java/org/jboss/identity/api2/RealmManager.java
trunk/identity-impl/src/main/java/org/jboss/identity/impl/store/ldap/LDAPIdentityStore.java
trunk/identity-impl/src/main/java/org/jboss/identity/impl/types/SimpleGroup.java
trunk/identity-impl/src/main/java/org/jboss/identity/impl/types/SimpleIdentityObject.java
Log:
api2 -> api (step 1/3)
Modified: trunk/identity-api/src/main/java/org/jboss/identity/api2/RealmManager.java
===================================================================
--- trunk/identity-api/src/main/java/org/jboss/identity/api2/RealmManager.java 2008-09-20
19:34:02 UTC (rev 98)
+++ trunk/identity-api/src/main/java/org/jboss/identity/api2/RealmManager.java 2008-09-20
20:08:05 UTC (rev 99)
@@ -23,8 +23,8 @@
package org.jboss.identity.api2;
import org.jboss.identity.exception.IdentityException;
-import org.jboss.identity.api.exception.PersistenceManagerNotFoundException;
-import org.jboss.identity.api.exception.SessionNotOpenException;
+import org.jboss.identity.api2.exception.PersistenceManagerNotFoundException;
+import org.jboss.identity.api2.exception.SessionNotOpenException;
import java.io.InputStream;
@@ -60,8 +60,8 @@
* @param realmA
* @param realmB
* @param relationshipType
- * @throws org.jboss.identity.api.exception.PersistenceManagerNotFoundException PM not
set
- * @throws org.jboss.identity.api.exception.SessionNotOpenException session is not
open
+ * @throws org.jboss.identity.api2.exception.PersistenceManagerNotFoundException PM
not set
+ * @throws org.jboss.identity.api2.exception.SessionNotOpenException session is not
open
*/
void associate(Realm realmA, Realm realmB, RelationshipType relationshipType)
throws PersistenceManagerNotFoundException, SessionNotOpenException;
Copied: trunk/identity-api/src/main/java/org/jboss/identity/api2/event/IdentityEvent.java
(from rev 84,
trunk/identity-api/src/main/java/org/jboss/identity/api/event/IdentityEvent.java)
===================================================================
--- trunk/identity-api/src/main/java/org/jboss/identity/api2/event/IdentityEvent.java
(rev 0)
+++
trunk/identity-api/src/main/java/org/jboss/identity/api2/event/IdentityEvent.java 2008-09-20
20:08:05 UTC (rev 99)
@@ -0,0 +1,31 @@
+/*
+* JBoss, a division of Red Hat
+* Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
+* by the @authors tag. See the copyright.txt in the distribution for a
+* full listing of individual contributors.
+*
+* This is free software; you can redistribute it and/or modify it
+* under the terms of the GNU Lesser General Public License as
+* published by the Free Software Foundation; either version 2.1 of
+* the License, or (at your option) any later version.
+*
+* This software is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+* Lesser General Public License for more details.
+*
+* You should have received a copy of the GNU Lesser General Public
+* License along with this software; if not, write to the Free
+* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+* 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
+*/
+
+package org.jboss.identity.api2.event;
+
+/**
+ * @author boleslaw dot dawidowicz at redhat anotherdot com
+ * @version : 0.1 $
+ */
+public class IdentityEvent
+{
+}
\ No newline at end of file
Copied:
trunk/identity-api/src/main/java/org/jboss/identity/api2/event/IdentityEventBroadcaster.java
(from rev 84,
trunk/identity-api/src/main/java/org/jboss/identity/api/event/IdentityEventBroadcaster.java)
===================================================================
---
trunk/identity-api/src/main/java/org/jboss/identity/api2/event/IdentityEventBroadcaster.java
(rev 0)
+++
trunk/identity-api/src/main/java/org/jboss/identity/api2/event/IdentityEventBroadcaster.java 2008-09-20
20:08:05 UTC (rev 99)
@@ -0,0 +1,42 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2006, Red Hat Middleware, LLC, and individual *
+ * contributors as indicated by the @authors tag. See the *
+ * copyright.txt in the distribution for a full listing of *
+ * individual contributors. *
+ * *
+ * This is free software; you can redistribute it and/or modify it *
+ * under the terms of the GNU Lesser General Public License as *
+ * published by the Free Software Foundation; either version 2.1 of *
+ * the License, or (at your option) any later version. *
+ * *
+ * This software is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
+ * Lesser General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU Lesser General Public *
+ * License along with this software; if not, write to the Free *
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
+ * 02110-1301 USA, or see the FSF site:
http://www.fsf.org. *
+ ******************************************************************************/
+package org.jboss.identity.api2.event;
+
+import org.jboss.identity.api.event.*;
+import org.jboss.identity.api.event.IdentityEvent;
+
+/**
+ * Interface that allow event firing.
+ *
+ * @author <a href="mailto:julien@jboss.org">Julien Viet</a>
+ * @version $Revision: 1.1 $
+ */
+public interface IdentityEventBroadcaster
+{
+ /**
+ * Fire an event.
+ *
+ * @param event the event to fire
+ */
+ void fireEvent(IdentityEvent event);
+}
\ No newline at end of file
Copied:
trunk/identity-api/src/main/java/org/jboss/identity/api2/event/IdentityEventEmitter.java
(from rev 84,
trunk/identity-api/src/main/java/org/jboss/identity/api/event/IdentityEventEmitter.java)
===================================================================
---
trunk/identity-api/src/main/java/org/jboss/identity/api2/event/IdentityEventEmitter.java
(rev 0)
+++
trunk/identity-api/src/main/java/org/jboss/identity/api2/event/IdentityEventEmitter.java 2008-09-20
20:08:05 UTC (rev 99)
@@ -0,0 +1,48 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2006, Red Hat Middleware, LLC, and individual *
+ * contributors as indicated by the @authors tag. See the *
+ * copyright.txt in the distribution for a full listing of *
+ * individual contributors. *
+ * *
+ * This is free software; you can redistribute it and/or modify it *
+ * under the terms of the GNU Lesser General Public License as *
+ * published by the Free Software Foundation; either version 2.1 of *
+ * the License, or (at your option) any later version. *
+ * *
+ * This software is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
+ * Lesser General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU Lesser General Public *
+ * License along with this software; if not, write to the Free *
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
+ * 02110-1301 USA, or see the FSF site:
http://www.fsf.org. *
+ ******************************************************************************/
+package org.jboss.identity.api2.event;
+
+import org.jboss.identity.api.event.IdentityEventListener;
+
+/**
+ * Interface that allows registration management of identity event listeners.
+ *
+ * @author <a href="mailto:julien@jboss.org">Julien Viet</a>
+ * @version $Revision: 1.1 $
+ */
+public interface IdentityEventEmitter
+{
+ /**
+ * Add a listener.
+ *
+ * @param listener the listener for all identity events
+ */
+ void addListener(IdentityEventListener listener);
+
+ /**
+ * Remove a listener.
+ *
+ * @param listener the listener
+ */
+ void removeListener(IdentityEventListener listener);
+}
\ No newline at end of file
Copied:
trunk/identity-api/src/main/java/org/jboss/identity/api2/event/IdentityEventListener.java
(from rev 84,
trunk/identity-api/src/main/java/org/jboss/identity/api/event/IdentityEventListener.java)
===================================================================
---
trunk/identity-api/src/main/java/org/jboss/identity/api2/event/IdentityEventListener.java
(rev 0)
+++
trunk/identity-api/src/main/java/org/jboss/identity/api2/event/IdentityEventListener.java 2008-09-20
20:08:05 UTC (rev 99)
@@ -0,0 +1,42 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2006, Red Hat Middleware, LLC, and individual *
+ * contributors as indicated by the @authors tag. See the *
+ * copyright.txt in the distribution for a full listing of *
+ * individual contributors. *
+ * *
+ * This is free software; you can redistribute it and/or modify it *
+ * under the terms of the GNU Lesser General Public License as *
+ * published by the Free Software Foundation; either version 2.1 of *
+ * the License, or (at your option) any later version. *
+ * *
+ * This software is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
+ * Lesser General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU Lesser General Public *
+ * License along with this software; if not, write to the Free *
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
+ * 02110-1301 USA, or see the FSF site:
http://www.fsf.org. *
+ ******************************************************************************/
+package org.jboss.identity.api2.event;
+
+import org.jboss.identity.api.event.*;
+import org.jboss.identity.api.event.IdentityEvent;
+
+/**
+ * An event listener.
+ *
+ * @author <a href="mailto:julien@jboss.org">Julien Viet</a>
+ * @version $Revision: 1.1 $
+ */
+public interface IdentityEventListener
+{
+ /**
+ * Fire event on the listener.
+ *
+ * @param event the identity event
+ */
+ void onEvent(IdentityEvent event);
+}
\ No newline at end of file
Copied:
trunk/identity-api/src/main/java/org/jboss/identity/api2/exception/PersistenceManagerNotFoundException.java
(from rev 84,
trunk/identity-api/src/main/java/org/jboss/identity/api/exception/PersistenceManagerNotFoundException.java)
===================================================================
---
trunk/identity-api/src/main/java/org/jboss/identity/api2/exception/PersistenceManagerNotFoundException.java
(rev 0)
+++
trunk/identity-api/src/main/java/org/jboss/identity/api2/exception/PersistenceManagerNotFoundException.java 2008-09-20
20:08:05 UTC (rev 99)
@@ -0,0 +1,35 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
+ */
+package org.jboss.identity.api2.exception;
+
+import org.jboss.identity.exception.IdentityException;
+
+/**
+ * Exception indicating the non-availability
+ * of a Persistence Manager
+ * @author Anil.Saldhana(a)redhat.com
+ * @since Jul 10, 2008
+ */
+public class PersistenceManagerNotFoundException extends IdentityException
+{
+ private static final long serialVersionUID = 1L;
+}
\ No newline at end of file
Copied:
trunk/identity-api/src/main/java/org/jboss/identity/api2/exception/SessionNotOpenException.java
(from rev 84,
trunk/identity-api/src/main/java/org/jboss/identity/api/exception/SessionNotOpenException.java)
===================================================================
---
trunk/identity-api/src/main/java/org/jboss/identity/api2/exception/SessionNotOpenException.java
(rev 0)
+++
trunk/identity-api/src/main/java/org/jboss/identity/api2/exception/SessionNotOpenException.java 2008-09-20
20:08:05 UTC (rev 99)
@@ -0,0 +1,35 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
+ */
+package org.jboss.identity.api2.exception;
+
+import org.jboss.identity.exception.IdentityException;
+
+/**
+ * Exception indicating that no session
+ * is open
+ * @author Anil.Saldhana(a)redhat.com
+ * @since Jul 10, 2008
+ */
+public class SessionNotOpenException extends IdentityException
+{
+ private static final long serialVersionUID = 1L;
+}
\ No newline at end of file
Modified:
trunk/identity-impl/src/main/java/org/jboss/identity/impl/store/ldap/LDAPIdentityStore.java
===================================================================
---
trunk/identity-impl/src/main/java/org/jboss/identity/impl/store/ldap/LDAPIdentityStore.java 2008-09-20
19:34:02 UTC (rev 98)
+++
trunk/identity-impl/src/main/java/org/jboss/identity/impl/store/ldap/LDAPIdentityStore.java 2008-09-20
20:08:05 UTC (rev 99)
@@ -428,7 +428,9 @@
throw new NotYetImplementedException();
}
- public <T extends IdentityObjectType> Set<String>
getSupportedAttributeNames(IdentityStoreInvocationContext invocationContext, T
identityType) throws IdentityException
+ // Attributes
+
+ public Set<String> getSupportedAttributeNames(IdentityStoreInvocationContext
invocationContext, IdentityObjectType identityType) throws IdentityException
{
//TODO: NYI
throw new NotYetImplementedException();
Modified:
trunk/identity-impl/src/main/java/org/jboss/identity/impl/types/SimpleGroup.java
===================================================================
---
trunk/identity-impl/src/main/java/org/jboss/identity/impl/types/SimpleGroup.java 2008-09-20
19:34:02 UTC (rev 98)
+++
trunk/identity-impl/src/main/java/org/jboss/identity/impl/types/SimpleGroup.java 2008-09-20
20:08:05 UTC (rev 99)
@@ -23,9 +23,9 @@
import java.util.List;
-import org.jboss.identity.api.Group;
-import org.jboss.identity.api.GroupType;
import org.jboss.identity.exception.PolicyValidationException;
+import org.jboss.identity.api2.Group;
+import org.jboss.identity.api2.GroupType;
/**
* A simple implementation of group
Modified:
trunk/identity-impl/src/main/java/org/jboss/identity/impl/types/SimpleIdentityObject.java
===================================================================
---
trunk/identity-impl/src/main/java/org/jboss/identity/impl/types/SimpleIdentityObject.java 2008-09-20
19:34:02 UTC (rev 98)
+++
trunk/identity-impl/src/main/java/org/jboss/identity/impl/types/SimpleIdentityObject.java 2008-09-20
20:08:05 UTC (rev 99)
@@ -26,12 +26,12 @@
import java.util.Map;
import java.util.Set;
-import org.jboss.identity.api.Group;
-import org.jboss.identity.api.Role;
import org.jboss.identity.exception.PolicyValidationException;
import org.jboss.identity.spi.model.IdentityObject;
import org.jboss.identity.spi.model.IdentityObjectAttribute;
import org.jboss.identity.spi.model.IdentityObjectType;
+import org.jboss.identity.api2.Group;
+import org.jboss.identity.api2.Role;
/**