如何在java manifest classpath中使用正则表达式? [英] How to use regular expression in java manifest classpath?
本文介绍了如何在java manifest classpath中使用正则表达式?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我需要在程序执行期间使用额外的jar。我手动将jar添加到相对的./lib文件夹,然后执行该程序。我应该如何在清单文件中定义类路径?
I need to make use of additional jars during the execution of the program. I manually add the jars to the relative ./lib folder and then execute the program. How should I define the classpath in the manifest file?
推荐答案
您不能在<$中使用正则表达式或其他通配符c $ c>清单的Class-Path 属性。
Java中只有一个支持的通配符,只有在指定的情况下才能使用在命令行上的手动 java
调用(即不使用 -jar
):使用 directoryname / *
。
There is only one supported wildcard in Java, and that only works on if specified on the commandline on a "manual" java
invocation (i.e. not using -jar
): using directoryname/*
.
这篇关于如何在java manifest classpath中使用正则表达式?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文