Jar Contents for External Lib in Language

I'm calling a static method from the canSubstitute method of an action of my language. This static method is defined in a class found in a third-party library which I've added to my language (I've attached it both as a javaclasses model root and in the Java > Library section of the language properties).

This static method attempts to load another file from the classpath located within its own JAR. When it attempts to do this, it says that it can't find the file on the classpath. So when my action tries to determine canSubstitute, I get an IDE error. The library in question is the Clojure language JAR itself, so I'm confident the third-party code works as expected, and I can execute this same method in a separate Solution module (using baseLanguage + library stubs) without any issues, just not within my action.

Questions:

  1. Is there a way for me to see the classpath of the correct classloader in this situation?
  2. Is there something about the way MPS runs action aspects that would prevent Java code used in an action from dynamically loading a resource from the classpath like this?
1

Please sign in to leave a comment.