in my maven project, the resources folder look like this:
- resources
- images
- TestImage.png
- images
If I call
System.out.println(MainClass.class.getClassLoader().getResource("images"));
I get "file:/C:/Users/XYZXYZ/IdeaProjects/projectName/core/target/classes/images/"
If I add the file name like this:
System.out.println(MainClass.class.getClassLoader().getResource("images/TestImage.png"));
I get "null". How is this possible? What happens here?
Edit: I noticed that it works (does not give null anymore), as soon as I delete my module-info.java Problem: I need my module-info.java. Any tips?