* Typically called through ReflectiveLoadTimeWeaver.
* @see org.springframework.instrument.classloading.LoadTimeWeaver#getThrowawayClassLoader
* @see org.springframework.instrument.classloading.ReflectiveLoadTimeWeaver
*/
public ClassLoader getThrowawayClassLoader() {
WebappClassLoader tempLoader = new WebappClassLoader();
// Use reflection to copy all the fields since they are not exposed any other way.
shallowCopyFieldState(this, tempLoader);
return tempLoader;
}