Interface HotSwapClassesRedefinitionsListener
public interface HotSwapClassesRedefinitionsListener
A listener for classes redefinitions.
-
Method Summary
Modifier and TypeMethodDescriptionvoidclassRedefined(Class<?> redefinedClass) Called when a watched class is redefined.The class(es) to watch.booleanShould this listener be enabled?
-
Method Details
-
isEnabled
boolean isEnabled()Should this listener be enabled?In most cases, you only want to be able to auto reload classes during development.
When this method return
false, the listener is not registered, at all.A common pattern for this method is to use:
return getSpincastConfig().isDevelopmentMode();
-
getClassesToWatch
The class(es) to watch. -
classRedefined
Called when a watched class is redefined.Receives the class that was modified.
The method is called in a new Thread.
-