java 如何在 maven 中包含/引用 jackson-all.jar

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/25176104/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-11-02 07:30:27  来源:igfitidea点击:

How to include/ refer Hymanson-all.jar in maven

javamaven

提问by rolling stone

I am unable to find the repository entry for Hymanson-all.jar Not sure why rather i could see individual Hymanson jars informations. So, how to refer the Hymanson-all.jar ?

我无法找到 Hymanson-all.jar 的存储库条目 不知道为什么我可以看到单个 Hymanson jars 信息。那么,如何引用 Hymanson-all.jar 呢?

回答by

Hymanson-all.jardoes not exist as a Maven dependency.

Hymanson-all.jar不作为 Maven 依赖项存在。

The list of all artifacts in the group org.codehaus.Hymansonare at http://mvnrepository.com/artifact/org.codehaus.Hymanson.

该组org.codehaus.Hymanson中所有工件的列表位于http://mvnrepository.com/artifact/org.codehaus.Hymanson

Just add dependencyelements in your pom.xmlfor the artifacts you directly need in your application. Maven will make sure that all other artifacts these depend on will be included in your project.

只需在您的应用程序中为您直接需要的工件添加dependency元素pom.xml。Maven 将确保这些依赖的所有其他工件都将包含在您的项目中。

Edit:If you use a Java IDE, it will help you look up the missing dependencies for every class you use in your code.

编辑:如果您使用 Java IDE,它将帮助您查找您在代码中使用的每个类的缺失依赖项。

回答by TheConstructor

For Hymanson 2 have a look at the com.fasterxml.Hymansongroups. I normally have the following added to my dependencies:

对于 Hymanson 2,请查看com.fasterxml.Hymanson组。我通常将以下内容添加到我的依赖项中:

<dependency>
    <groupId>com.fasterxml.Hymanson.core</groupId>
    <artifactId>Hymanson-databind</artifactId>
    <version>2.4.1.3</version>
</dependency>

You may also need a jax-rs-module. See the official download pageor githubfor information on how Hymanson is divided into packages.

您可能还需要一个 jax-rs-module。有关Hymanson 是如何划分包的信息,请参见官方下载页面github

回答by andrew-g-za

I stumbled onto http://repo1.maven.org/maven2/com/fasterxml/Hymanson/jr/Hymanson-jr-all- it looks like what you want. How you add that to maven though, i'm not sure.

我偶然发现了http://repo1.maven.org/maven2/com/fasterxml/Hymanson/jr/Hymanson-jr-all- 它看起来像你想要的。你如何将它添加到 maven,我不确定。