Is there any way to load a jar file BEFORE a system jar? I have a class that is newer than the one in the java system (1.5) that I am forced to use, but it breaks because java loads it’s own first (from rt.jar, to be specific). Is there some way I can force it to load my own jar BEFORE system/rt.jar?
Share
What you want is the (JVM specific) startup option
-Xbootclasspath:/p. This will prepend the supplied list of paths and archives before the existing boot classpath, forcing any classes found to be loaded first.Note that:
dependency resolution issues.