Spring: finding resources in the internal bank

I have this military structure: Some.war

-WEB-INF
--lib
--- library.jar
---- some.xsd
---- some2.xsd

And I want to get all xsd files in library.jar, but spring doesn't want to look for it.

ContextLoaderListener.getCurrentWebApplicationContext()
                     .getResources("classpath*:**/*.xsd")

the result is empty. I also tried: classpath:**/*.xsd, **/*.xsd.

How can I get all xsd files in the bank using the ant (* /. Xsd) template?

+3
source share
1 answer

The answer lies with Spring docs:

4.7.2.3 Other wildcard notes

, "classpath *:", Ant , . "classpath *: *. xml" jar, root .. JDK ClassLoader.getResources(), ( ).

+7

All Articles