Return the class loader to be used for instantiating application objects when required. This is determined based upon the following rules: The class loader set by setClassLoader() , if any The thread context class loader, if it exists and the useContextClassLoader
()
| 547 | * @return the classloader |
| 548 | */ |
| 549 | public ClassLoader getClassLoader() { |
| 550 | if (this.classLoader != null) { |
| 551 | return this.classLoader; |
| 552 | } |
| 553 | if (this.useContextClassLoader) { |
| 554 | ClassLoader classLoader = Thread.currentThread().getContextClassLoader(); |
| 555 | if (classLoader != null) { |
| 556 | return classLoader; |
| 557 | } |
| 558 | } |
| 559 | return this.getClass().getClassLoader(); |
| 560 | } |
| 561 | |
| 562 | |
| 563 | /** |
no test coverage detected