How to import dcm4che library to java project?

ε祈祈猫儿з 提交于 2019-12-05 00:53:30

Using Apache Maven is of course the best and easiest option. You will need to add the dcm4che repository as well as the dcm4che dependencies into your pom (see details below).

Once you have the pom ready, make sure everything compiles by a 'mvn clean install'. Import the required classes appropriately inside your application's classes.

Add repository to the pom:

<repositories>
<repository>
    <id>www.dcm4che.org</id>
    <name>dcm4che Repository</name>
    <url>http://www.dcm4che.org/maven2</url>
</repository>
</repositories>

Add dependency to the pom:

<dependency> 
    <groupId>dcm4che</groupId>
    <artifactId>dcm4che-core</artifactId>
    <version>2.0.29</version>
</dependency>

You dont say what your intended use is -

  • Do you want to use the library in another application and just need the jar? If so then mvn install will have already added the dcm4che into your maven repository so you should be able to configure your IDE workspace to use this repository
  • Do you want to work on the dcm4che project in your IDE to contribute to the project? The you should just import the maven project from the downloaded directory, or from github
标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!