directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ersi...@apache.org
Subject svn commit: r539735 - /directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/
Date Sat, 19 May 2007 11:35:53 GMT
Author: ersiner
Date: Sat May 19 04:35:52 2007
New Revision: 539735

URL: http://svn.apache.org/viewvc?view=rev&rev=539735
Log:
More generalization for Trigger code.

Modified:
    directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/AbstractStoredProcedureParameterInjector.java
    directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/AddStoredProcedureParameterInjector.java
    directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/DeleteStoredProcedureParameterInjector.java
    directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/StoredProcedureParameterInjector.java
    directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/TriggerService.java

Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/AbstractStoredProcedureParameterInjector.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/AbstractStoredProcedureParameterInjector.java?view=diff&rev=539735&r1=539734&r2=539735
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/AbstractStoredProcedureParameterInjector.java
(original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/AbstractStoredProcedureParameterInjector.java
Sat May 19 04:35:52 2007
@@ -72,14 +72,14 @@
         this.invocation = invocation;
     }
     
-    public final List getArgumentsToInject( List parameterList ) throws NamingException
+    public final List<Object> getArgumentsToInject( List<StoredProcedureParameter>
parameterList ) throws NamingException
     {
-        List arguments = new ArrayList();
+        List<Object> arguments = new ArrayList<Object>();
         
-        Iterator it = parameterList.iterator();
+        Iterator<StoredProcedureParameter> it = parameterList.iterator();
         while ( it.hasNext() )
         {
-            StoredProcedureParameter spParameter = ( StoredProcedureParameter ) it.next();
+            StoredProcedureParameter spParameter = it.next();
             MicroInjector injector = injectors.get( spParameter.getClass() );
             arguments.add( injector.inject( spParameter ) );
         }
@@ -101,7 +101,7 @@
         {
             Generic_LDAP_CONTEXT ldapCtxParam = ( Generic_LDAP_CONTEXT ) param;
             LdapDN ldapCtxName = ldapCtxParam.getCtxName();
-            return (( ServerLdapContext ) ( ( ServerLdapContext ) invocation.getCaller()
).getRootContext()).lookup( ldapCtxName );
+            return ( ( ServerLdapContext ) ( ( ServerLdapContext ) invocation.getCaller()
).getRootContext()).lookup( ldapCtxName );
         };
     };
 

Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/AddStoredProcedureParameterInjector.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/AddStoredProcedureParameterInjector.java?view=diff&rev=539735&r1=539734&r2=539735
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/AddStoredProcedureParameterInjector.java
(original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/AddStoredProcedureParameterInjector.java
Sat May 19 04:35:52 2007
@@ -39,7 +39,7 @@
         super( invocation );
         this.addedEntryName = addedEntryName;
         this.addedEntry = addedEntry;
-        Map injectors = super.getInjectors();
+        Map<Class, MicroInjector> injectors = super.getInjectors();
         injectors.put( StoredProcedureParameter.Add_ENTRY.class, $entryInjector );
         injectors.put( StoredProcedureParameter.Add_ATTRIBUTES.class, $attributesInjector
);
     }

Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/DeleteStoredProcedureParameterInjector.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/DeleteStoredProcedureParameterInjector.java?view=diff&rev=539735&r1=539734&r2=539735
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/DeleteStoredProcedureParameterInjector.java
(original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/DeleteStoredProcedureParameterInjector.java
Sat May 19 04:35:52 2007
@@ -43,7 +43,7 @@
         super( invocation );
         this.deletedEntryName = deletedEntryName;
         this.deletedEntry = getDeletedEntry();
-        Map injectors = super.getInjectors();
+        Map<Class, MicroInjector> injectors = super.getInjectors();
         injectors.put( StoredProcedureParameter.Delete_NAME.class, $nameInjector );
         injectors.put( StoredProcedureParameter.Delete_DELETED_ENTRY.class, $deletedEntryInjector
);
     }

Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/StoredProcedureParameterInjector.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/StoredProcedureParameterInjector.java?view=diff&rev=539735&r1=539734&r2=539735
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/StoredProcedureParameterInjector.java
(original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/StoredProcedureParameterInjector.java
Sat May 19 04:35:52 2007
@@ -28,7 +28,7 @@
 
 public interface StoredProcedureParameterInjector
 {
-    List<Object> getArgumentsToInject( List parameterList ) throws NamingException;
+    List<Object> getArgumentsToInject( List<StoredProcedureParameter> parameterList
) throws NamingException;
     
     public interface MicroInjector
     {

Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/TriggerService.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/TriggerService.java?view=diff&rev=539735&r1=539734&r2=539735
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/TriggerService.java
(original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/TriggerService.java
Sat May 19 04:35:52 2007
@@ -560,11 +560,11 @@
     {
         Object result = null;
         
-        Iterator it = triggerSpecs.iterator();
+        Iterator<TriggerSpecification> it = triggerSpecs.iterator();
         
         while( it.hasNext() )
         {
-            TriggerSpecification tsec = ( TriggerSpecification ) it.next();
+            TriggerSpecification tsec = it.next();
             
             // TODO: Replace the Authorization Code with a REAL one.
             if ( triggerExecutionAuthorizer.hasPermission() )



Mime
View raw message