Top "Javassist" questions

Javassist is a class library for editing bytecode in java.

Can a Java class add a method to itself at runtime?

Can a class add a method to itself at runtime (like from a static block), so that if someone is …

java reflection code-generation javassist
Reflections - Java 8 - invalid constant type

I have a problem with Reflections library. I am trying to load dynamically all classes which implement specific interface. Everything …

java java-8 javassist reflections
PowerMock Mockito [PowerMockito] @PrepareForTest -> java.lang.NoClassDefFoundError: javassist/NotFoundException

I'm trying to use my 1st PowerMockito [PowerMock + Mockito] mock in an existing JUnit test. I've narrowed down that when …

java junit mockito powermock javassist
Adding an annotation to a runtime generated method/class using Javassist

I'm using Javassist to generate a class foo, with method bar, but I can't seem to find a way to …

java annotations javassist
PowerMock and Java 8 issue: InterfaceMethodrefInfo cannot be cast to MethodrefInfo

I´m having issues while trying to execute a unit test using PowerMock with Mockito. I need PowerMockito to mock …

java powermock javassist
Bad <init> method call from inside of a branch

After upgrading JDK to java7u65 several unit-tests utilizing Mockito and PowerMock started to fail with following causes: 15:15:23,807 INFO - …

java maven powermock javassist
Javassist. What is the main idea and where real use?

I know that Javassist is a Java library providing a means to manipulate the Java bytecode of an application. Ok, …

java bytecode javassist
Javassist add method and invoke

I'm stuck with javassist. I've added a new method to my object class on runtime. My object class: package tmp3; …

java javassist
Configure org.apache.log4j.ConsoleAppender with custom classloader

I have a java class which creates a custom classloader based on javassist class loader on start up and then …

java log4j classloader javassist
Getting Javassist types instead of actual Hibernate entity types

I have stumbled upon a really annoying situation: I am using Hibernate & Spring as backend for my app and …

java hibernate spring javassist