Skip to main content

Bytecode Preprocessor

No replies
kblim
Offline
Joined: 2013-08-05
Points: 0

Hi All!

I have tried for few days already to enable the bytecode preprocessor in the Glassfish jvm settings.
But I was unable to get it to work.

This is the value for bytecode preprocessor i have set "com.idb.bytecodePreprocessor.BytecodePreprocessorImp.class".

Bellow is my preprocessor class.

Hope to get some help. Thanks first!

//-----------------------------------------------------------------------------------------------------
package com.idb.bytecodePreprocessor;

import com.sun.appserv.BytecodePreprocessor;
import java.util.Hashtable;

/**
*
* @author kblim
*/
public class BytecodePreprocessorImp implements BytecodePreprocessor{
public boolean initialize(Hashtable parameters){
System.out.print("initialize");
return true;
}

public byte[] preprocess(String classname, byte[] classBytes){
System.out.print(classname);

return classBytes;

}
}

//-----------------------------------------------------------------------------------------------------