如何使用 Java 创建安装程序?

发布于 2024-08-28 11:52:05 字数 1539 浏览 5 评论 0原文

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(4

猥琐帝 2024-09-04 11:52:05

在 Windows 中,您可以使用高级安装程序。

Advanced Installer 是唯一内置对 Java 应用程序支持的 Windows Installer 创作工具,可将它们完全集成到 Windows 操作系统中,并使它们的外观和感觉就像本机应用程序一样。

使用高级安装程序,您可以为 Java 应用程序创建 MSI 包,并允许您的应用程序使用 Windows Installer 功能。

http://www.advancedinstaller.com/java.html

In windows you can use Advanced Installer .

Advanced Installer is the only Windows Installer authoring tool with built-in support for Java applications, integrating them fully into the Windows OS and making them look and feel just like a native application.

Using Advanced Installer you can create MSI packages for your Java applications, and allow your application to use the Windows Installer features.

http://www.advancedinstaller.com/java.html

爱她像谁 2024-09-04 11:52:05

这是一个非常模糊的问题。您想安装什么?选项包括:

  1. JRE ?
  2. 您的应用程序(.jar)?
  3. 注册表项?
  4. 配置文件?

没有这样的 Java API。如果您需要安装 JRE,那么您可以查看现有的部署机制,例如 .rpm(其他存在)并声明对 JRE 的依赖关系。这样,您选择的软件包管理器将部署您的所有先决条件。

This is such a vague question. What do you want to install ? Options include:

  1. the JRE ?
  2. your application (a .jar) ?
  3. Registry entries ?
  4. Configuration files ?

There's no such Java API. If you need to install the JRE, then you could look at an existing deployment mechanism such as .rpm (others exist) and declare a dependency on a JRE. That way your chosen package manager will deploy all your pre-requisites.

箜明 2024-09-04 11:52:05

这是一个高度专业化的主题,如果在这里看到一个满足您对知识需求的答案,我会感到非常惊讶。如果你认真对待这一点,你应该准备好自己的工作来研究概念和实施策略。

建议:

  1. 调查现有工具的用途;例如,通过阅读所有可用的用户文档。至少从高层的角度来看,他们如何实现大部分工作应该是非常明显的。

  2. 下载一个或多个开源产品的源代码并阅读代码以了解其工作原理/它们的工作原理。

  3. 开始设计和构建您自己的工具并发展您自己的实践知识。

This is a highly specialized topic, and I would be very surprised to see an answer here that satisfies your need for knowledge. If you are serious about this, you should be prepared to do your own work to research the concepts and implementation strategies.

Suggestions:

  1. Survey what the existing tools do; e.g. by reading all of the available user documentation. It should be pretty obvious how they achieve most of the things that they do, at least from a high-level perspective.

  2. Download the source code for one or more of the open-source products and read the code to figure out how it works / they work.

  3. Start designing and building your own tool and develop your own practical knowledge.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文