java - When does Class#getClassLoader return null? -


say have java code:

public class widget {     ...whatever } 

and code classloads widget:

classloader widgetloader = widget.class.getclassloader(); 

can widgetloader ever null? why/why not? if so, under circumstances?

according method javadoc:

returns class loader class. implementations may use null represent bootstrap class loader. method return null in such implementations if class loaded bootstrap class loader.


Comments

Popular posts from this blog

How to mention the localhost in android -

php - Calling a template part from a post -

c# - String.format() DateTime With Arabic culture -