private static synchronized void createFixedAnyConstructor() {
if (fixedAnyConstructor != null) {
return;
}
ASMHelper helper = new ASMHelper();
ClassWriter cw = helper.createClassWriter();
FieldVisitor fv;
cw.visit(Opcodes.V1_5, Opcodes.ACC_PUBLIC + Opcodes.ACC_SUPER,
"org/apache/cxf/binding/corba/utils/FixedAnyImpl",
null, "com/sun/corba/se/impl/corba/AnyImpl", null);
cw.visitSource("FixedAnyImpl.java", null);
fv = cw.visitField(0, "obj", "Lorg/omg/CORBA/portable/Streamable;", null, null);
fv.visitEnd();
addFixedAnyConstructor(helper, cw);
addInsertOverride(helper, cw);
addExtractOverride(helper, cw);
addReadOverride(helper, cw);
addWriteOverride(helper, cw);
cw.visitEnd();
byte[] b = cw.toByteArray();
Class<?> c = helper.loadClass("org.apache.cxf.binding.corba.utils.FixedAnyImpl",
CorbaAnyHelper.class, b);
try {
fixedAnyConstructor = c.getConstructor(ORB.class, Any.class);
} catch (Exception e) {
//shouldn't happen since we generated that constructor