fr.ifremer.isisfish.aspect
Class RuleAspect

java.lang.Object
  extended by fr.ifremer.isisfish.aspect.RuleAspect

public class RuleAspect
extends Object

Aspect utiliser pour intersepecter les appels a Rule.init(SimulationContext), Rule.preAction(SimulationContext, TimeStep, Metier), Rule.postAction(SimulationContext, TimeStep, Metier) et memoriser le temps mit.

Version:
$Revision: 3437 $ Last update : $Date: 2011-07-08 13:26:05 +0200 (Fri, 08 Jul 2011) $ By : $Author$
Author:
chatellier

Nested Class Summary
protected static class RuleAspect.State
          State phase to register.
 
Constructor Summary
RuleAspect()
           
 
Method Summary
 Object initCall(org.codehaus.aspectwerkz.joinpoint.JoinPoint jp)
          Aspect around Rule.init(SimulationContext) in packages "rules".
 Object initPostCall(org.codehaus.aspectwerkz.joinpoint.JoinPoint jp)
          Aspect around Rule.postAction(SimulationContext, TimeStep, Metier) in packages "rules".
 Object initPreCall(org.codehaus.aspectwerkz.joinpoint.JoinPoint jp)
          Aspect around Rule.preAction(SimulationContext, TimeStep, Metier) in packages "rules".
protected  Object makeTimedCall(org.codehaus.aspectwerkz.joinpoint.JoinPoint jp, RuleAspect.State state)
          Effectue l'appel reel en calculant le temps pris.
protected  void registerTime(org.codehaus.aspectwerkz.joinpoint.JoinPoint jp, RuleAspect.State state, long timeTaken)
          Add time (init/pre/post) to simulation information in current SimulationContext.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RuleAspect

public RuleAspect()
Method Detail

initCall

public Object initCall(org.codehaus.aspectwerkz.joinpoint.JoinPoint jp)
                throws Throwable
Aspect around Rule.init(SimulationContext) in packages "rules".

Parameters:
jp - join point
Returns:
init result
Throws:
Throwable

initPreCall

public Object initPreCall(org.codehaus.aspectwerkz.joinpoint.JoinPoint jp)
                   throws Throwable
Aspect around Rule.preAction(SimulationContext, TimeStep, Metier) in packages "rules".

Parameters:
jp - join point
Returns:
preAction result
Throws:
Throwable

initPostCall

public Object initPostCall(org.codehaus.aspectwerkz.joinpoint.JoinPoint jp)
                    throws Throwable
Aspect around Rule.postAction(SimulationContext, TimeStep, Metier) in packages "rules".

Parameters:
jp - join point
Returns:
preAction result
Throws:
Throwable

makeTimedCall

protected Object makeTimedCall(org.codehaus.aspectwerkz.joinpoint.JoinPoint jp,
                               RuleAspect.State state)
                        throws Throwable
Effectue l'appel reel en calculant le temps pris.

Parameters:
jp - join point
state - state
Throws:
Throwable

registerTime

protected void registerTime(org.codehaus.aspectwerkz.joinpoint.JoinPoint jp,
                            RuleAspect.State state,
                            long timeTaken)
Add time (init/pre/post) to simulation information in current SimulationContext.

Parameters:
jp - join point
state - state
timeTaken - time taken by state


Copyright © 1999-2012 CodeLutin. All Rights Reserved.