eclipse - Xuggler 初学者设置指南

标签 eclipse maven jar pom.xml xuggler

要使用 Xuggler,您需要 xuggle-xuggler-5.4.jar。据做这个的人说,大多数用户只需要上面提到的JAR文件。然而,这就是他们关于使用 Xuggler 没有 Maven 或 Ivy 的说法:

Using Xuggler WITHOUT Apache Maven or Apache Ivy

What are you... stuck in 2003? Anyway, if you insist on this, Xuggler's pre-compiled binaries (including native versions) can be found here. Make sure that xuggle-xuggler.jar and its dependencies are included in your Java classpath. See the xuggle-xugger-*.pom file distributed with the version of Xuggler that you use to find the (small) set of dependent jars, and download them as well.

我下载了最新版本 5.4 的 xuggle-xuggler.jar 文件,但我不理解它的 pom 文件。

  • 他说的是什么依赖性
  • 接下来,如何下载这些依赖项
  • 获得这些依赖项后,如何开始在 Eclipse 中工作?



  • 下载依赖后更新

    我有以下目录结构:
    enter image description here

  • xuggle-xuggler-5.4.jar 存放在E:\xuggle
  • enter image description here
  • 各种 xuggler 依赖项 存储在 E:\xuggle\xuggle-dependencies
  • 问题:

  • 我如何开始在 Eclipse 中使用 Xuggler?我必须设置什么路径以及这些路径有什么值?
  • 最佳答案

    以下文件列出了 xuggle 依赖的其他 jar:

    您可以阅读这些内容,然后从适当的存储库中手动检索它们,但我认为开始使用依赖项管理器会更简单。

    你问如何下载这些依赖项,ivy有一个方便的command-line操作模式。 (见下面的例子)

    Eclipse 集成非常困难……一旦您下载了 jar,您就可以尝试生成“.classpath”文件或通过 Eclipse GUI 手动添加每个 jar。 我不推荐这种方法的原因是因为有适用于 Maven 和 Ivy 的 Eclipse 插件可以自动为您执行此操作。

    例子

    从命令行运行 ivy,如下所示:

    java -jar ivy.jar -settings ivysettings.xml -dependency xuggle xuggle-xuggler 5.4 -retrieve "lib/[artifact]-[revision].[ext]"
    

    它将 xuggle 及其所有依赖项检索到“lib”目录中,如下所示:

    ├── ivysettings.xml
    └── lib
        ├── commons-cli-1.1.jar
        ├── logback-classic-1.0.0.jar
        ├── logback-core-1.0.0.jar
        ├── slf4j-api-1.6.4.jar
        └── xuggle-xuggler-5.4.jar
    

    Ivy 设置.xml

    此文件告诉 ivy 从 Maven Central 中检索 jars ,或 Xuggle 项目提供的 Maven 存储库。

    <ivysettings>
        <settings defaultResolver="repos" />
        <resolvers>
            <chain name="repos">
                <ibiblio name="central" m2compatible="true"/>
                <ibiblio name="xuggle" m2compatible="true" root="http://xuggle.googlecode.com/svn/trunk/repo/share/java"/>
            </chain>
        </resolvers>
    </ivysettings>
    

    关于eclipse - Xuggler 初学者设置指南,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/14534870/

    相关文章:

    eclipse - 在 Eclipse + jboss 5.1.0 中获取 "java.lang.ClassNotFoundException: javax.servlet.http.HttpServlet"

    android - 如何设置 Artifact 库根名称

    java - Maven:从另一个模块导入目标文件夹

    我想在 HTML 中运行 Java 程序

    jar - 在源代码中和编译期间包含 jar 文件

    c++ - Linux 上的托管构建

    java - Eclipse 上的哪个选项可以定义 "{"和 "}"将在同一行并自动完成?

    java.lang.Integer.parseInt 不会取 0xFFFFFFFF

    java - Maven: versions:update-parent 后跟 install 安装旧版本

    java - 从 jar 导入 java 库类时,这是否被视为静态链接?还是动态的?