File privateKeyFile = new File(this.getClass().getClassLoader().getResource("privateKey").getFile());
successfully gives me a keyFile. If I now list the path with:
debug successfully shows me a path to the file:
However, as soon as I try and read that file with
Method threw 'java.nio.file.NoSuchFileException' exception.
This is really confusing, and I've tried changing the
getResource() to various things like
getResource("/privateKey"); - yet that errors a lot sooner, actually a NPE right when trying to create a
new File(), so the file MUST exist as I've shown above??