[jboss-cvs] JBossAS SVN: r84607 - in projects/aop/branches/createspi/aop/src/main/java/org/jboss/aop: plugins and 1 other directories.

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Mon Feb 23 06:07:33 EST 2009


Author: kabir.khan at jboss.com
Date: 2009-02-23 06:07:33 -0500 (Mon, 23 Feb 2009)
New Revision: 84607

Modified:
   projects/aop/branches/createspi/aop/src/main/java/org/jboss/aop/AspectManager.java
   projects/aop/branches/createspi/aop/src/main/java/org/jboss/aop/Domain.java
   projects/aop/branches/createspi/aop/src/main/java/org/jboss/aop/plugins/DefaultManager.java
   projects/aop/branches/createspi/aop/src/main/java/org/jboss/aop/spi/Manager.java
Log:
Add Interface Introduction, Interceptor Factory, Typedef and Dynamic cflow to the new Manager

Modified: projects/aop/branches/createspi/aop/src/main/java/org/jboss/aop/AspectManager.java
===================================================================
--- projects/aop/branches/createspi/aop/src/main/java/org/jboss/aop/AspectManager.java	2009-02-23 11:02:37 UTC (rev 84606)
+++ projects/aop/branches/createspi/aop/src/main/java/org/jboss/aop/AspectManager.java	2009-02-23 11:07:33 UTC (rev 84607)
@@ -132,7 +132,7 @@
    protected volatile WeakHashMap<Domain, Object> subscribedSubDomainsQueue = UnmodifiableEmptyCollections.EMPTY_WEAK_HASHMAP;
    protected int subscribedDomainQueueRef;
 
-   protected volatile LinkedHashMap<String, InterfaceIntroduction> interfaceIntroductions = UnmodifiableEmptyCollections.EMPTY_LINKED_HASHMAP;
+//   protected volatile LinkedHashMap<String, InterfaceIntroduction> interfaceIntroductions = UnmodifiableEmptyCollections.EMPTY_LINKED_HASHMAP;
    protected volatile LinkedHashMap<String, ArrayReplacement> arrayReplacements = UnmodifiableEmptyCollections.EMPTY_LINKED_HASHMAP;
    protected volatile LinkedHashMap<String, ArrayBinding> arrayBindings = UnmodifiableEmptyCollections.EMPTY_LINKED_HASHMAP;
    protected volatile LinkedHashMap<String, AnnotationIntroduction> annotationIntroductions =UnmodifiableEmptyCollections. EMPTY_LINKED_HASHMAP;
@@ -140,12 +140,12 @@
    @Deprecated
    protected volatile LinkedHashMap<String, AdviceBinding> bindings = UnmodifiableEmptyCollections.EMPTY_LINKED_HASHMAP;
    protected final ClassifiedBindingAndPointcutCollection bindingCollection;
-   protected volatile LinkedHashMap<String, Typedef> typedefs = UnmodifiableEmptyCollections.EMPTY_LINKED_HASHMAP;
-   protected volatile HashMap<String, InterceptorFactory> interceptorFactories = UnmodifiableEmptyCollections.EMPTY_HASHMAP;
+   //protected volatile LinkedHashMap<String, Typedef> typedefs = UnmodifiableEmptyCollections.EMPTY_LINKED_HASHMAP;
+//   protected volatile HashMap<String, InterceptorFactory> interceptorFactories = UnmodifiableEmptyCollections.EMPTY_HASHMAP;
    protected volatile HashMap<String,ClassMetaDataLoader> classMetaDataLoaders = UnmodifiableEmptyCollections.EMPTY_HASHMAP;
    protected volatile HashMap<String, AdviceStack> interceptorStacks = UnmodifiableEmptyCollections.EMPTY_HASHMAP;
    protected volatile HashMap<String, DeclareDef> declares = UnmodifiableEmptyCollections.EMPTY_HASHMAP;
-   protected volatile ConcurrentHashMap<String, DynamicCFlowDefinition> dynamicCFlows = UnmodifiableEmptyCollections.EMPTY_CONCURRENT_HASHMAP;
+   //protected volatile ConcurrentHashMap<String, DynamicCFlowDefinition> dynamicCFlows = UnmodifiableEmptyCollections.EMPTY_CONCURRENT_HASHMAP;
    protected volatile ConcurrentHashMap<String, AspectDefinition> aspectDefinitions = UnmodifiableEmptyCollections.EMPTY_CONCURRENT_HASHMAP;
    protected volatile ConcurrentHashMap<String, Object> perVMAspects = UnmodifiableEmptyCollections.EMPTY_CONCURRENT_HASHMAP;
 
@@ -304,31 +304,23 @@
    {
       return getDynamicCFlow(name, SecurityActions.getContextClassLoader());
    }
-   
+
+   @Deprecated
    public DynamicCFlow getDynamicCFlow(String name, ClassLoader cl)
    {
-      DynamicCFlowDefinition def = dynamicCFlows.get(name);
-
-      if (def != null)
-      {
-         return def.create(cl);
-      }
-      return null;
+      return manager.getDynamicCFlow(name, cl);
    }
 
-
-   /* (non-Javadoc)
-    * @see org.jboss.aop.Manager#addDynamicCFlow(java.lang.String, org.jboss.aop.advice.DynamicCFlowDefinition)
-    */
+   @Deprecated
    public void addDynamicCFlow(String name, DynamicCFlowDefinition cflow)
    {
-      initDynamicCflowsMap();
-      dynamicCFlows.put(name, cflow);
+      manager.addDynamicCFlow(name, cflow);
    }
 
+   @Deprecated
    public void removeDynamicCFlow(String name)
    {
-      dynamicCFlows.remove(name);
+      manager.removeDynamicCFlow(name);
    }
 
    /**
@@ -839,43 +831,28 @@
       return AOPSystem.getWeaver().translate(className, loader, classfileBuffer);
    }
 
-   /**
-    * Add an interceptor factory that can be referenced by name.
-    */
+   @Deprecated
    public void addInterceptorFactory(String name, InterceptorFactory factory)
    {
-      initInterceptorFactoriesMap();
-      synchronized (interceptorFactories)
-      {
-         interceptorFactories.put(name, factory);
-      }
+      manager.addInterceptorFactory(name, factory);
    }
 
-   /**
-    * Remove an interceptor factory that can be referenced by name.
-    */
+   @Deprecated
    public void removeInterceptorFactory(String name)
    {
-      synchronized (interceptorFactories)
-      {
-         interceptorFactories.remove(name);
-      }
+      manager.removeInterceptorFactory(name);
    }
 
+   @Deprecated
    public Map<String, InterceptorFactory> getInterceptorFactories()
    {
-      return interceptorFactories;
+      return manager.getInterceptorFactories();
    }
 
-   /**
-    * Find the interceptor factory that can be referenced by name.
-    */
+   @Deprecated
    public InterceptorFactory getInterceptorFactory(String name)
    {
-      synchronized (interceptorFactories)
-      {
-         return interceptorFactories.get(name);
-      }
+      return manager.getInterceptorFactory(name);
    }
 
 
@@ -1385,41 +1362,22 @@
 
    //--- Introductions
 
-   /**
-    * Retrieve an introduction pointcut of a certain name
-    */
+   @Deprecated
    public InterfaceIntroduction getInterfaceIntroduction(String name)
    {
-      synchronized (interfaceIntroductions)
-      {
-         return interfaceIntroductions.get(name);
-      }
+      return manager.getInterfaceIntroduction(name);
    }
 
-   /**
-    * Register an introduction pointcut
-    */
-   public synchronized void addInterfaceIntroduction(InterfaceIntroduction pointcut)
+   @Deprecated
+   public synchronized void addInterfaceIntroduction(InterfaceIntroduction introduction)
    {
-      removeInterfaceIntroduction(pointcut.getName());
-      initInterfaceIntroductionsMap();
-      synchronized (interfaceIntroductions)
-      {
-         interfaceIntroductions.put(pointcut.getName(), pointcut);
-      }
+      manager.addInterfaceIntroduction(introduction);
    }
 
-   /**
-    * remove an introduction pointcut of a certain name
-    */
+   @Deprecated
    public void removeInterfaceIntroduction(String name)
    {
-      synchronized (interfaceIntroductions)
-      {
-         InterfaceIntroduction pointcut = interfaceIntroductions.remove(name);
-         if (pointcut == null) return;
-         pointcut.clearAdvisors();
-      }
+      manager.removeInterfaceIntroduction(name);
    }
 
    /**
@@ -1754,35 +1712,28 @@
       return aspectDefinitions.get(name);
    }
 
+   @Deprecated
    public synchronized void addTypedef(Typedef def) throws Exception
    {
-      removeTypedef(def.getName());
-      initTypedefsMap();
-      synchronized (typedefs)
-      {
-         typedefs.put(def.getName(), def);
-      }
+      manager.addTypedef(def);
    }
 
+   @Deprecated
    public void removeTypedef(String name)
    {
-      synchronized (typedefs)
-      {
-         typedefs.remove(name);
-      }
+      manager.removeTypedef(name);
    }
 
+   @Deprecated
    public Typedef getTypedef(String name)
    {
-      synchronized (typedefs)
-      {
-         return typedefs.get(name);
-      }
+      return manager.getTypedef(name);
    }
 
+   @Deprecated
    public Map<String, InterfaceIntroduction> getInterfaceIntroductions()
    {
-      return interfaceIntroductions;
+      return manager.getInterfaceIntroductions();
    }
 
    public Map<String, ArrayReplacement> getArrayReplacements()
@@ -1790,9 +1741,10 @@
       return arrayReplacements;
    }
 
+   @Deprecated
    public Map<String, Typedef> getTypedefs()
    {
-      return typedefs;
+      return manager.getTypedefs();
    }
 
    public Map<String, AdviceStack> getInterceptorStacks()
@@ -1810,9 +1762,10 @@
       return manager.getCFlowStacks();
    }
 
+   @Deprecated
    public Map<String, DynamicCFlowDefinition> getDynamicCFlows()
    {
-      return dynamicCFlows;
+      return manager.getDynamicCFlows();
    }
 
    public Map<String, Object> getPerVMAspects()
@@ -2055,20 +2008,6 @@
       }
    }
 
-   protected void initInterfaceIntroductionsMap()
-   {
-      if (interfaceIntroductions == UnmodifiableEmptyCollections.EMPTY_LINKED_HASHMAP)
-      {
-         synchronized(lazyCollectionLock)
-         {
-            if (interfaceIntroductions == UnmodifiableEmptyCollections.EMPTY_LINKED_HASHMAP)
-            {
-               interfaceIntroductions = new LinkedHashMap<String, InterfaceIntroduction>();
-            }
-         }
-      }
-   }
-
    protected void initArrayReplacementMap()
    {
       if (arrayReplacements == UnmodifiableEmptyCollections.EMPTY_LINKED_HASHMAP)
@@ -2126,34 +2065,6 @@
       }
    }
 
-   protected void initTypedefsMap()
-   {
-      if (typedefs == UnmodifiableEmptyCollections.EMPTY_LINKED_HASHMAP)
-      {
-         synchronized(lazyCollectionLock)
-         {
-            if (typedefs == UnmodifiableEmptyCollections.EMPTY_LINKED_HASHMAP)
-            {
-               typedefs = new LinkedHashMap<String, Typedef>();
-            }
-         }
-      }
-   }
-
-   protected void initInterceptorFactoriesMap()
-   {
-      if (interceptorFactories == UnmodifiableEmptyCollections.EMPTY_HASHMAP)
-      {
-         synchronized(lazyCollectionLock)
-         {
-            if (interceptorFactories == UnmodifiableEmptyCollections.EMPTY_HASHMAP)
-            {
-               interceptorFactories = new HashMap<String, InterceptorFactory>();
-            }
-         }
-      }
-   }
-
    protected void initClassMetaDataLoadersMap()
    {
       if (classMetaDataLoaders == UnmodifiableEmptyCollections.EMPTY_HASHMAP)
@@ -2197,20 +2108,6 @@
       }
    }
 
-   protected void initDynamicCflowsMap()
-   {
-      if (dynamicCFlows == UnmodifiableEmptyCollections.EMPTY_CONCURRENT_HASHMAP)
-      {
-         synchronized(lazyCollectionLock)
-         {
-            if (dynamicCFlows == UnmodifiableEmptyCollections.EMPTY_CONCURRENT_HASHMAP)
-            {
-               dynamicCFlows = new ConcurrentHashMap<String, DynamicCFlowDefinition>();
-            }
-         }
-      }
-   }
-
    protected void initAspectDefintitionsMap()
    {
       if (aspectDefinitions == UnmodifiableEmptyCollections.EMPTY_CONCURRENT_HASHMAP)

Modified: projects/aop/branches/createspi/aop/src/main/java/org/jboss/aop/Domain.java
===================================================================
--- projects/aop/branches/createspi/aop/src/main/java/org/jboss/aop/Domain.java	2009-02-23 11:02:37 UTC (rev 84606)
+++ projects/aop/branches/createspi/aop/src/main/java/org/jboss/aop/Domain.java	2009-02-23 11:07:33 UTC (rev 84607)
@@ -406,17 +406,17 @@
          {
             // when child first, parent bindings go in first so that they can be overridden by child.
             map.putAll(parent.getInterfaceIntroductions());
-            synchronized (interfaceIntroductions)
+            synchronized (getInterfaceIntroductions())
             {
-               map.putAll(interfaceIntroductions);
+               map.putAll(getInterfaceIntroductions());
             }
             return map;
          }
          else
          {
-            synchronized (interfaceIntroductions)
+            synchronized (getInterfaceIntroductions())
             {
-               map.putAll(interfaceIntroductions);
+               map.putAll(getInterfaceIntroductions());
             }
             map.putAll(parent.getInterfaceIntroductions());
             return map;
@@ -441,7 +441,7 @@
    public void removeInterfaceIntroduction(String name)
    {
       super.removeInterfaceIntroduction(name);
-      hasOwnInterfaceIntroductions = interfaceIntroductions.size() > 0;
+      hasOwnInterfaceIntroductions = getInterfaceIntroductions().size() > 0;
    }
    
    @Override
@@ -454,17 +454,17 @@
          {
             // when child first, parent bindings go in first so that they can be overridden by child.
             map.putAll(parent.getTypedefs());
-            synchronized (typedefs)
+            synchronized (getTypedefs())
             {
-               map.putAll(typedefs);
+               map.putAll(getTypedefs());
             }
             return map;
          }
          else
          {
-            synchronized (typedefs)
+            synchronized (getTypedefs())
             {
-               map.putAll(typedefs);
+               map.putAll(getTypedefs());
             }
             map.putAll(parent.getTypedefs());
             return map;
@@ -490,7 +490,7 @@
    public void removeTypedef(String name)
    {
       super.removeTypedef(name);
-      hasOwnTypedefs = typedefs.size() > 0;
+      hasOwnTypedefs = getTypedefs().size() > 0;
    }
 
    public Map<String, AdviceStack> getInterceptorStacks()
@@ -591,17 +591,17 @@
          {
             // when child first, parent bindings go in first so that they can be overridden by child.
             map.putAll(parent.getDynamicCFlows());
-            synchronized (dynamicCFlows)
+            synchronized (getDynamicCFlows())
             {
-               map.putAll(dynamicCFlows);
+               map.putAll(getDynamicCFlows());
             }
             return map;
          }
          else
          {
-            synchronized (dynamicCFlows)
+            synchronized (getDynamicCFlows())
             {
-               map.putAll(dynamicCFlows);
+               map.putAll(getDynamicCFlows());
             }
             map.putAll(parent.getDynamicCFlows());
             return map;

Modified: projects/aop/branches/createspi/aop/src/main/java/org/jboss/aop/plugins/DefaultManager.java
===================================================================
--- projects/aop/branches/createspi/aop/src/main/java/org/jboss/aop/plugins/DefaultManager.java	2009-02-23 11:02:37 UTC (rev 84606)
+++ projects/aop/branches/createspi/aop/src/main/java/org/jboss/aop/plugins/DefaultManager.java	2009-02-23 11:07:33 UTC (rev 84607)
@@ -22,10 +22,17 @@
 package org.jboss.aop.plugins;
 
 import java.util.Collections;
+import java.util.HashMap;
+import java.util.LinkedHashMap;
 import java.util.Map;
 import java.util.concurrent.ConcurrentHashMap;
 
+import org.jboss.aop.advice.DynamicCFlowDefinition;
+import org.jboss.aop.advice.InterceptorFactory;
+import org.jboss.aop.introduction.InterfaceIntroduction;
 import org.jboss.aop.pointcut.CFlowStack;
+import org.jboss.aop.pointcut.DynamicCFlow;
+import org.jboss.aop.pointcut.Typedef;
 import org.jboss.aop.spi.Configuration;
 import org.jboss.aop.spi.Manager;
 import org.jboss.aop.util.UnmodifiableEmptyCollections;
@@ -42,7 +49,15 @@
    
    private final Object lazyCollectionLock = new Object();
    
-   protected volatile ConcurrentHashMap<String, CFlowStack> cflowStacks = UnmodifiableEmptyCollections.EMPTY_CONCURRENT_HASHMAP;
+   private volatile Map<String, CFlowStack> cflowStacks = UnmodifiableEmptyCollections.EMPTY_CONCURRENT_HASHMAP;
+   
+   private volatile Map<String, DynamicCFlowDefinition> dynamicCFlows = UnmodifiableEmptyCollections.EMPTY_CONCURRENT_HASHMAP;
+   
+   private volatile Map<String, Typedef> typedefs = UnmodifiableEmptyCollections.EMPTY_CONCURRENT_HASHMAP;
+   
+   private volatile Map<String, InterceptorFactory> interceptorFactories = UnmodifiableEmptyCollections.EMPTY_HASHMAP;
+   
+   private volatile LinkedHashMap<String, InterfaceIntroduction> interfaceIntroductions = UnmodifiableEmptyCollections.EMPTY_LINKED_HASHMAP;
 
    protected DefaultManager(Configuration configuration)
    {
@@ -69,7 +84,118 @@
    {
       return Collections.unmodifiableMap(cflowStacks);
    }
+   
+   public void addDynamicCFlow(String name, DynamicCFlowDefinition cflow)
+   {
+      initDynamicCflowsMap();
+      dynamicCFlows.put(name, cflow);
+   }
 
+   public DynamicCFlow getDynamicCFlow(String name, ClassLoader cl)
+   {
+      DynamicCFlowDefinition def = dynamicCFlows.get(name);
+
+      if (def != null)
+      {
+         return def.create(cl);
+      }
+      return null;
+   }
+
+   public void removeDynamicCFlow(String name)
+   {
+      dynamicCFlows.remove(name);
+   }
+
+   public Map<String, DynamicCFlowDefinition> getDynamicCFlows()
+   {
+      return dynamicCFlows;
+   }
+
+   public void addTypedef(Typedef def)
+   {
+      initTypedefsMap();
+      typedefs.put(def.getName(), def);
+   }
+
+   public void removeTypedef(String name)
+   {
+      typedefs.remove(name);
+   }
+
+   public Typedef getTypedef(String name)
+   {
+      return typedefs.get(name);
+   }
+
+   public Map<String, Typedef> getTypedefs()
+   {
+      return typedefs;
+   }
+
+   public void addInterceptorFactory(String name, InterceptorFactory factory)
+   {
+      initInterceptorFactoriesMap();
+      synchronized (interceptorFactories)
+      {
+         interceptorFactories.put(name, factory);
+      }
+   }
+
+   public InterceptorFactory getInterceptorFactory(String name)
+   {
+      synchronized (interceptorFactories)
+      {
+         return interceptorFactories.get(name);
+      }
+   }
+
+   public void removeInterceptorFactory(String name)
+   {
+      synchronized (interceptorFactories)
+      {
+         interceptorFactories.remove(name);
+      }
+   }
+
+   public Map<String, InterceptorFactory> getInterceptorFactories()
+   {
+      return interceptorFactories;
+   }
+   
+   public InterfaceIntroduction getInterfaceIntroduction(String name)
+   {
+      synchronized (interfaceIntroductions)
+      {
+         return interfaceIntroductions.get(name);
+      }
+   }
+
+   public synchronized void addInterfaceIntroduction(InterfaceIntroduction introduction)
+   {
+      removeInterfaceIntroduction(introduction.getName());
+      initInterfaceIntroductionsMap();
+      synchronized (interfaceIntroductions)
+      {
+         interfaceIntroductions.put(introduction.getName(), introduction);
+      }
+   }
+
+   public void removeInterfaceIntroduction(String name)
+   {
+      synchronized (interfaceIntroductions)
+      {
+         InterfaceIntroduction pointcut = interfaceIntroductions.remove(name);
+         if (pointcut == null) return;
+         pointcut.clearAdvisors();
+      }
+   }
+
+   public Map<String, InterfaceIntroduction> getInterfaceIntroductions()
+   {
+      return interfaceIntroductions;
+   }
+
    protected void initCFlowStacksMap()
    {
       if (cflowStacks == UnmodifiableEmptyCollections.EMPTY_CONCURRENT_HASHMAP)
@@ -83,4 +209,60 @@
          }
       }
    }
+   
+   protected void initDynamicCflowsMap()
+   {
+      if (dynamicCFlows == UnmodifiableEmptyCollections.EMPTY_CONCURRENT_HASHMAP)
+      {
+         synchronized(lazyCollectionLock)
+         {
+            if (dynamicCFlows == UnmodifiableEmptyCollections.EMPTY_CONCURRENT_HASHMAP)
+            {
+               dynamicCFlows = new ConcurrentHashMap<String, DynamicCFlowDefinition>();
+            }
+         }
+      }
+   }
+
+   protected void initTypedefsMap()
+   {
+      if (typedefs == UnmodifiableEmptyCollections.EMPTY_LINKED_HASHMAP)
+      {
+         synchronized(lazyCollectionLock)
+         {
+            if (typedefs == UnmodifiableEmptyCollections.EMPTY_LINKED_HASHMAP)
+            {
+               typedefs = new LinkedHashMap<String, Typedef>();
+            }
+         }
+      }
+   }
+
+   protected void initInterceptorFactoriesMap()
+   {
+      if (interceptorFactories == UnmodifiableEmptyCollections.EMPTY_HASHMAP)
+      {
+         synchronized(lazyCollectionLock)
+         {
+            if (interceptorFactories == UnmodifiableEmptyCollections.EMPTY_HASHMAP)
+            {
+               interceptorFactories = new HashMap<String, InterceptorFactory>();
+            }
+         }
+      }
+   }
+   
+   protected void initInterfaceIntroductionsMap()
+   {
+      if (interfaceIntroductions == UnmodifiableEmptyCollections.EMPTY_LINKED_HASHMAP)
+      {
+         synchronized(lazyCollectionLock)
+         {
+            if (interfaceIntroductions == UnmodifiableEmptyCollections.EMPTY_LINKED_HASHMAP)
+            {
+               interfaceIntroductions = new LinkedHashMap<String, InterfaceIntroduction>();
+            }
+         }
+      }
+   }
 }

Modified: projects/aop/branches/createspi/aop/src/main/java/org/jboss/aop/spi/Manager.java
===================================================================
--- projects/aop/branches/createspi/aop/src/main/java/org/jboss/aop/spi/Manager.java	2009-02-23 11:02:37 UTC (rev 84606)
+++ projects/aop/branches/createspi/aop/src/main/java/org/jboss/aop/spi/Manager.java	2009-02-23 11:07:33 UTC (rev 84607)
@@ -23,7 +23,12 @@
 
 import java.util.Map;
 
+import org.jboss.aop.advice.DynamicCFlowDefinition;
+import org.jboss.aop.advice.InterceptorFactory;
+import org.jboss.aop.introduction.InterfaceIntroduction;
 import org.jboss.aop.pointcut.CFlowStack;
+import org.jboss.aop.pointcut.DynamicCFlow;
+import org.jboss.aop.pointcut.Typedef;
 
 /**
  * 
@@ -32,15 +37,136 @@
  */
 public interface Manager
 {
+   /**
+    * Adds a cflow stack
+    * @param stack The cflow stack
+    */
+   void addCFlowStack(CFlowStack stack);
+   
+   /**
+    * Gets a cflow stack
+    * @param name The name of the cflow stack
+    * @return The Cflow stack or null if not found
+    */
    CFlowStack getCFlowStack(String name);
    
-   void addCFlowStack(CFlowStack stack);
-   
+   /**
+    * Removes a cflow stack
+    * @param name The name of the cflow stack 
+    */
    void removeCFlowStack(String name);
    
+   /**
+    * Get all the cflow stacks in this manager and parents
+    * @return a map of cflow stacks indexed by name
+    */
    Map<String, CFlowStack> getCFlowStacks();
+   
+   /**
+    * Adds a dynamic cflow definitition
+    * @param cflow The cflow definitition
+    */
+   void addDynamicCFlow(String name, DynamicCFlowDefinition cflow);
 
+   /**
+    * Gets a dynamic cflow
+    * @param name The name of the dynamic cflow
+    * @param The classloader to use loading the dynamic cflow
+    * @return The dynamic cflow
+    */
+   //TODO should this just return the defintion and make it up to the caller to create it?
+   DynamicCFlow getDynamicCFlow(String name, ClassLoader cl);
+
+   /**
+    * Removes a dynamic cflow definition
+    * @param name The name of the dynamic cflow definition 
+    */
+   void removeDynamicCFlow(String name);
+
+   /**
+    * Get all the dynamic cflows in this manager and parents
+    * @return a map of dynamic cflow definitions indexed by name
+    */
+   Map<String, DynamicCFlowDefinition> getDynamicCFlows();
+
+   /**
+    * Adds a typedef
+    * @param cflow The typedef definitition
+    */
+   void addTypedef(Typedef def);
+
+   /**
+    * Removes a typedef
+    * @param name The name of the typedef 
+    */
+   void removeTypedef(String name);
+
+   /**
+    * Gets a typedef
+    * @param name The name of the typedef
+    * @return The typedef or null if not found
+    */
+   Typedef getTypedef(String name);
+
+   /**
+    * Get all the typedefs in this manager and parents
+    * @return a map of typedefs indexed by name
+    */
+   Map<String, Typedef> getTypedefs();
+
+   /**
+    * Adds an interceptor factory
+    * @param name the name of the interceptor factory
+    * @param factory the name
+    */
+   //@FIXME Don't require name?
+   void addInterceptorFactory(String name, InterceptorFactory factory);
+
+   /**
+    * Gets an interceptor factory
+    * @param name The name of the interceptor factory
+    * @return The interceptor factory or null if not found
+    */
+   InterceptorFactory getInterceptorFactory(String name);
+
+   /**
+    * Removes an interceptor factory
+    * @param name The name of the interceptor factory 
+    */
+   void removeInterceptorFactory(String name);
+
+   /**
+    * Get all the interceptor factories in this manager and parents
+    * @return a map of interceptor factories indexed by name
+    */
+   Map<String, InterceptorFactory> getInterceptorFactories();
    
+   /**
+    * Adds an interface introduction
+    * @param introduction the introduction
+    */
+   void addInterfaceIntroduction(InterfaceIntroduction introduction);
+
+   /**
+    * Gets an interceptor factory
+    * @param name The name of the introduction
+    * @return The introduction or null if not found
+    */
+   InterfaceIntroduction getInterfaceIntroduction(String name);
+
+   /**
+    * Removes an introduction
+    * @param name The name of the introduction
+    */
+   void removeInterfaceIntroduction(String name);
+
+   /**
+    * Get all the introduction in this manager and parents
+    * @return a map of introductions indexed by name
+    */
+   Map<String, InterfaceIntroduction> getInterfaceIntroductions();
+
+   
 //   InterceptionMarkers getInterceptionMarkers(ClassLoader loader);
 //
 //   Map<String, Pointcut> getPointcuts();




More information about the jboss-cvs-commits mailing list