ch.elca.el4j.services.statistics.detailed.contextpassing
Class MeasureInterceptor

java.lang.Object
  extended by ch.elca.el4j.services.statistics.detailed.contextpassing.MeasureInterceptor
All Implemented Interfaces:
org.aopalliance.aop.Advice, org.aopalliance.intercept.Interceptor, org.aopalliance.intercept.MethodInterceptor

public class MeasureInterceptor
extends Object
implements org.aopalliance.intercept.MethodInterceptor

Invoker for measuring the time of calls to a EL4J service.

This invoker is not limited to a position. It may be used as Stub invoker or Proxy invoker.

Its configuration defines :

This class was ported from Leaf 2. Original authors: WHO, DBA. Leaf2 package name: ch.elca.leaf.services.measuring

Author:
Rashid Waraich (RWA), Philipp Oser (POS)
File-location:
MeasureInterceptor
Last check-in date:
2009-08-04 15:17:52 +0200 (Di, 04. Aug 2009) by swismer for revision 3880

Field Summary
protected static String s_hostName
          The host name.
 
Constructor Summary
MeasureInterceptor(MeasureCollectorService collectorService, boolean isServer)
          Deprecated. use the constructor with (MeasureCollectorService,String) instead
MeasureInterceptor(MeasureCollectorService collectorService, String vmName)
          The constructor.
 
Method Summary
 Map<String,String> getProxyMap()
          Returns the mapping between proxied class names and their substitutes.
 Object invoke(org.aopalliance.intercept.MethodInvocation methodInvocation)
          
 void setProxyMap(Map<String,String> proxyMap)
          Sets the mapping between proxied class names and their subsitutes.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

s_hostName

protected static String s_hostName
The host name.

Constructor Detail

MeasureInterceptor

public MeasureInterceptor(MeasureCollectorService collectorService,
                          boolean isServer)
Deprecated. use the constructor with (MeasureCollectorService,String) instead

The constructor.

Parameters:
collectorService - The collectorService, where the measured data should be stored to.
isServer - Is this a server (client=false).

MeasureInterceptor

public MeasureInterceptor(MeasureCollectorService collectorService,
                          String vmName)
The constructor.

Parameters:
collectorService - The collectorService, where the measured data should be stored to.
vmName - Name of the virual machine
Method Detail

invoke

public Object invoke(org.aopalliance.intercept.MethodInvocation methodInvocation)
              throws Throwable

Specified by:
invoke in interface org.aopalliance.intercept.MethodInterceptor
Throws:
Throwable

setProxyMap

public void setProxyMap(Map<String,String> proxyMap)
Sets the mapping between proxied class names and their subsitutes.

Parameters:
proxyMap - Fully qualified class names and respective short name of replacement. Leave value empty if proxied class should be ignored.

getProxyMap

public Map<String,String> getProxyMap()
Returns the mapping between proxied class names and their substitutes.

Returns:
Fully qualified class names and respective short name of replacement.


Copyright © 2005-2011 ELCA. All Rights Reserved.