com.uwyn.rife.instrument
Class RifeTransformer

java.lang.Object
  extended by com.uwyn.rife.instrument.RifeTransformer
All Implemented Interfaces:
ClassFileTransformer
Direct Known Subclasses:
ContinuationsTransformer, FinalTransformer, InitialTransformer, LazyLoadTransformer, MetaDataTransformer

public abstract class RifeTransformer
extends Object
implements ClassFileTransformer

An abstract base class that will only execute the bytecode transformation when the class is considered to not be part of a core package, like for example the JDK or the standard XML parsers.

Since:
1.6
Version:
$Revision: 3811 $
Author:
Geert Bevin (gbevin[remove] at uwyn dot com)

Constructor Summary
RifeTransformer()
           
 
Method Summary
 byte[] transform(ClassLoader loader, String className, Class<?> classBeingRedefined, ProtectionDomain protectionDomain, byte[] classfileBuffer)
           
protected abstract  byte[] transformRife(ClassLoader loader, String className, Class<?> classBeingRedefined, ProtectionDomain protectionDomain, byte[] classfileBuffer)
          This transform method will only be called when the class is not part of a core package.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RifeTransformer

public RifeTransformer()
Method Detail

transform

public final byte[] transform(ClassLoader loader,
                              String className,
                              Class<?> classBeingRedefined,
                              ProtectionDomain protectionDomain,
                              byte[] classfileBuffer)
                       throws IllegalClassFormatException
Specified by:
transform in interface ClassFileTransformer
Throws:
IllegalClassFormatException

transformRife

protected abstract byte[] transformRife(ClassLoader loader,
                                        String className,
                                        Class<?> classBeingRedefined,
                                        ProtectionDomain protectionDomain,
                                        byte[] classfileBuffer)
                                 throws IllegalClassFormatException
This transform method will only be called when the class is not part of a core package.

For the rest it functions exactly as the regular transform method.

Throws:
IllegalClassFormatException
Since:
1.6
See Also:
transform(java.lang.ClassLoader, java.lang.String, java.lang.Class, java.security.ProtectionDomain, byte[])


Copyright © 2001-2007 Uwyn sprl/bvba. All Rights Reserved.