FileDocCategorySizeDatePackage
MutexAspectFactory.javaAPI DocJBoss 4.2.12569Fri Jul 13 21:02:36 BST 2007org.jboss.aspects.concurrent

MutexAspectFactory

public class MutexAspectFactory extends Object implements org.jboss.aop.advice.AspectFactory
comment
author
Bill Burke

Fields Summary
Constructors Summary
Methods Summary
public java.lang.ObjectcreatePerClass(org.jboss.aop.Advisor advisor)

      throw new IllegalStateException("THIS SCOPE NOT USABLE");
   
public java.lang.ObjectcreatePerInstance(org.jboss.aop.Advisor advisor, org.jboss.aop.InstanceAdvisor instanceAdvisor)

      throw new IllegalStateException("THIS SCOPE NOT USABLE");
   
public java.lang.ObjectcreatePerJoinpoint(org.jboss.aop.Advisor advisor, org.jboss.aop.joinpoint.Joinpoint jp)

      MethodJoinpoint mj = (MethodJoinpoint)jp;
      MutexLocked props = (MutexLocked)advisor.resolveAnnotation(mj.getMethod(), MutexLocked.class);
      if (props.timeout() < 0)
      {
         return new MutexAspect.BlockingMutex();
      }
      else if (props.timeout() == 0)
      {
         return new MutexAspect.TryLockMutex();
      }
      else
      {
         return new MutexAspect.TimeoutMutex(props);
      }
   
public java.lang.ObjectcreatePerJoinpoint(org.jboss.aop.Advisor advisor, org.jboss.aop.InstanceAdvisor instanceAdvisor, org.jboss.aop.joinpoint.Joinpoint jp)

      throw new IllegalStateException("THIS SCOPE NOT USABLE");
   
public java.lang.ObjectcreatePerVM()

      throw new IllegalStateException("THIS SCOPE NOT USABLE");
   
public java.lang.StringgetName()

      return MutexAspectFactory.class.getName();